Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdolfo SBH2016-09-27 18:05:53 +0000
committerEd Willink2016-10-22 14:16:23 +0000
commit24a62bb4347cea76d98f83ce62a5a160ea36fbf9 (patch)
treec52de3acf4ab6fba56f47593bc5a528236867e70
parent50ffbac417f33066fba4df02d3a246ca54f56440 (diff)
downloadorg.eclipse.qvtd-24a62bb4347cea76d98f83ce62a5a160ea36fbf9.tar.gz
org.eclipse.qvtd-24a62bb4347cea76d98f83ce62a5a160ea36fbf9.tar.xz
org.eclipse.qvtd-24a62bb4347cea76d98f83ce62a5a160ea36fbf9.zip
[cs2as] - Regenerating code
- Removing the automatic generation of the CS2ASTreeOutlineView
-rw-r--r--doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/MiniOCLTables.java12
-rw-r--r--doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/lookup/EnvironmentTables.java12
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src-gen/org/eclipse/qvtd/doc/ui/AbstractMiniOCLCSUiModule.java6
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/MiniOCLCSUiModule.xtend11
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/outline/MiniOCLCSOutlineTreeProvider.xtend15
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/_MiniOCLCS2AS_qvtp_qvtcas/MiniOCLCS2AS_qvtp_qvtcas.java6549
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractComputationConstructor.java120
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractTransformerInternal.java518
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalInvocationManager.java66
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalObjectManager.java6
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyInvocationManager.java64
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyObjectManager.java8
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/library/model/ModelObjectsOfKindOperation.java4
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractCS2ASTransformer.java37
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocation.java8
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocationManager.java4
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractObjectManager.java5
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/TypedModelInstance.java3
-rw-r--r--doc/org.eclipse.qvtd.doc.minioclcs.xtext/src/org/eclipse/qvtd/doc/GenerateMiniOCLCS.mwe27
19 files changed, 3603 insertions, 3852 deletions
diff --git a/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/MiniOCLTables.java b/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/MiniOCLTables.java
index 663e9b0a4..872bae746 100644
--- a/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/MiniOCLTables.java
+++ b/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/MiniOCLTables.java
@@ -519,6 +519,10 @@ public class MiniOCLTables
/**
* The parameter lists shared by operations.
+ *
+ * @noextend This class is not intended to be subclassed by clients.
+ * @noinstantiate This class is not intended to be instantiated by clients.
+ * @noreference This class is not intended to be referenced by clients.
*/
public static class Parameters {
static {
@@ -539,6 +543,10 @@ public class MiniOCLTables
/**
* The operation descriptors for each operation of each type.
+ *
+ * @noextend This class is not intended to be subclassed by clients.
+ * @noinstantiate This class is not intended to be instantiated by clients.
+ * @noreference This class is not intended to be referenced by clients.
*/
public static class Operations {
static {
@@ -558,6 +566,10 @@ public class MiniOCLTables
/**
* The property descriptors for each property of each type.
+ *
+ * @noextend This class is not intended to be subclassed by clients.
+ * @noinstantiate This class is not intended to be instantiated by clients.
+ * @noreference This class is not intended to be referenced by clients.
*/
public static class Properties {
static {
diff --git a/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/lookup/EnvironmentTables.java b/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/lookup/EnvironmentTables.java
index de61d2cc3..2431fd183 100644
--- a/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/lookup/EnvironmentTables.java
+++ b/doc/org.eclipse.qvtd.doc.miniocl/emf-gen/org/eclipse/qvtd/doc/miniocl/lookup/EnvironmentTables.java
@@ -157,6 +157,10 @@ public class EnvironmentTables
/**
* The parameter lists shared by operations.
+ *
+ * @noextend This class is not intended to be subclassed by clients.
+ * @noinstantiate This class is not intended to be instantiated by clients.
+ * @noreference This class is not intended to be referenced by clients.
*/
public static class Parameters {
static {
@@ -179,6 +183,10 @@ public class EnvironmentTables
/**
* The operation descriptors for each operation of each type.
+ *
+ * @noextend This class is not intended to be subclassed by clients.
+ * @noinstantiate This class is not intended to be instantiated by clients.
+ * @noreference This class is not intended to be referenced by clients.
*/
public static class Operations {
static {
@@ -208,6 +216,10 @@ public class EnvironmentTables
/**
* The property descriptors for each property of each type.
+ *
+ * @noextend This class is not intended to be subclassed by clients.
+ * @noinstantiate This class is not intended to be instantiated by clients.
+ * @noreference This class is not intended to be referenced by clients.
*/
public static class Properties {
static {
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src-gen/org/eclipse/qvtd/doc/ui/AbstractMiniOCLCSUiModule.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src-gen/org/eclipse/qvtd/doc/ui/AbstractMiniOCLCSUiModule.java
index faeb6ce76..025a8db2c 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src-gen/org/eclipse/qvtd/doc/ui/AbstractMiniOCLCSUiModule.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src-gen/org/eclipse/qvtd/doc/ui/AbstractMiniOCLCSUiModule.java
@@ -16,7 +16,7 @@ import org.eclipse.qvtd.doc.ide.contentassist.antlr.internal.InternalMiniOCLCSLe
import org.eclipse.qvtd.doc.ui.contentassist.MiniOCLCSProposalProvider;
import org.eclipse.qvtd.doc.ui.labeling.MiniOCLCSDescriptionLabelProvider;
import org.eclipse.qvtd.doc.ui.labeling.MiniOCLCSLabelProvider;
-import org.eclipse.qvtd.doc.ui.outline.MiniOCLCSCS2ASOutlineTreeProvider;
+import org.eclipse.qvtd.doc.ui.outline.MiniOCLCSOutlineTreeProvider;
import org.eclipse.qvtd.doc.ui.quickfix.MiniOCLCSQuickfixProvider;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.eclipse.xtext.builder.BuilderParticipant;
@@ -196,12 +196,12 @@ public abstract class AbstractMiniOCLCSUiModule extends DefaultUiModule {
// contributed by org.eclipse.xtext.xtext.generator.ui.outline.OutlineTreeProviderFragment2
public Class<? extends IOutlineTreeProvider> bindIOutlineTreeProvider() {
- return MiniOCLCSCS2ASOutlineTreeProvider.class;
+ return MiniOCLCSOutlineTreeProvider.class;
}
// contributed by org.eclipse.xtext.xtext.generator.ui.outline.OutlineTreeProviderFragment2
public Class<? extends IOutlineTreeStructureProvider> bindIOutlineTreeStructureProvider() {
- return MiniOCLCSCS2ASOutlineTreeProvider.class;
+ return MiniOCLCSOutlineTreeProvider.class;
}
// contributed by org.eclipse.xtext.xtext.generator.ui.quickfix.QuickfixProviderFragment2
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/MiniOCLCSUiModule.xtend b/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/MiniOCLCSUiModule.xtend
index 77269744e..e6c8e038a 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/MiniOCLCSUiModule.xtend
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/MiniOCLCSUiModule.xtend
@@ -4,10 +4,21 @@
package org.eclipse.qvtd.doc.ui
import org.eclipse.xtend.lib.annotations.FinalFieldsConstructor
+import org.eclipse.qvtd.doc.ui.outline.MiniOCLCSCS2ASOutlineTreeProvider
/**
* Use this class to register components to be used within the Eclipse IDE.
*/
@FinalFieldsConstructor
class MiniOCLCSUiModule extends AbstractMiniOCLCSUiModule {
+
+
+ override bindIOutlineTreeProvider() {
+ return MiniOCLCSCS2ASOutlineTreeProvider;
+ }
+
+ override bindIOutlineTreeStructureProvider() {
+ return MiniOCLCSCS2ASOutlineTreeProvider;
+ }
+
}
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/outline/MiniOCLCSOutlineTreeProvider.xtend b/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/outline/MiniOCLCSOutlineTreeProvider.xtend
new file mode 100644
index 000000000..f64477510
--- /dev/null
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext.ui/src/org/eclipse/qvtd/doc/ui/outline/MiniOCLCSOutlineTreeProvider.xtend
@@ -0,0 +1,15 @@
+/*
+ * generated by Xtext 2.10.0
+ */
+package org.eclipse.qvtd.doc.ui.outline
+
+import org.eclipse.xtext.ui.editor.outline.impl.DefaultOutlineTreeProvider
+
+/**
+ * Customization of the default outline structure.
+ *
+ * See https://www.eclipse.org/Xtext/documentation/304_ide_concepts.html#outline
+ */
+class MiniOCLCSOutlineTreeProvider extends DefaultOutlineTreeProvider {
+
+}
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/_MiniOCLCS2AS_qvtp_qvtcas/MiniOCLCS2AS_qvtp_qvtcas.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/_MiniOCLCS2AS_qvtp_qvtcas/MiniOCLCS2AS_qvtp_qvtcas.java
index f97964fb4..c26ae7749 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/_MiniOCLCS2AS_qvtp_qvtcas/MiniOCLCS2AS_qvtp_qvtcas.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/_MiniOCLCS2AS_qvtp_qvtcas/MiniOCLCS2AS_qvtp_qvtcas.java
@@ -14,6 +14,7 @@ import java.util.List;
import org.eclipse.emf.ecore.EcorePackage;
import org.eclipse.jdt.annotation.NonNull;
import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.ocl.pivot.TypedElement;
import org.eclipse.ocl.pivot.evaluation.Executor;
import org.eclipse.ocl.pivot.ids.ClassId;
import org.eclipse.ocl.pivot.ids.CollectionTypeId;
@@ -24,6 +25,7 @@ import org.eclipse.ocl.pivot.ids.NsURIPackageId;
import org.eclipse.ocl.pivot.ids.PropertyId;
import org.eclipse.ocl.pivot.ids.RootPackageId;
import org.eclipse.ocl.pivot.ids.TypeId;
+import org.eclipse.ocl.pivot.internal.library.executor.AbstractEvaluationOperation;
import org.eclipse.ocl.pivot.library.classifier.ClassifierOclContainerOperation;
import org.eclipse.ocl.pivot.library.collection.CollectionAsOrderedSetOperation;
import org.eclipse.ocl.pivot.library.collection.CollectionSizeOperation;
@@ -44,6 +46,7 @@ import org.eclipse.ocl.pivot.values.InvalidValueException;
import org.eclipse.ocl.pivot.values.OrderedSetValue;
import org.eclipse.ocl.pivot.values.SequenceValue;
import org.eclipse.ocl.pivot.values.SetValue;
+import org.eclipse.qvtd.doc.miniocl.CallExp;
import org.eclipse.qvtd.doc.miniocl.Element;
import org.eclipse.qvtd.doc.miniocl.ExpressionInOCL;
import org.eclipse.qvtd.doc.miniocl.MiniOCLFactory;
@@ -65,6 +68,7 @@ import org.eclipse.qvtd.doc.minioclcs.ClassCS;
import org.eclipse.qvtd.doc.minioclcs.ExpCS;
import org.eclipse.qvtd.doc.minioclcs.MinioclcsPackage;
import org.eclipse.qvtd.doc.minioclcs.NameExpCS;
+import org.eclipse.qvtd.doc.minioclcs.NavigationExpCS;
import org.eclipse.qvtd.doc.minioclcs.OperationCS;
import org.eclipse.qvtd.doc.minioclcs.PackageCS;
import org.eclipse.qvtd.doc.minioclcs.ParameterCS;
@@ -98,6 +102,7 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull NsURIPackageId PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS = IdManager.getNsURIPackageId("http://www.eclipse.org/qvtd/doc/MiniOCLCS", null, MinioclcsPackage.eINSTANCE);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull NsURIPackageId PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0 = IdManager.getNsURIPackageId("http://www.eclipse.org/qvtd/doc/MiniOCL/1.0", null, MiniOCLPackage.eINSTANCE);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_CSTrace = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS.getClassId("CSTrace", 0);
+ public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_CallExp = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("CallExp", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_CallExpCS = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS.getClassId("CallExpCS", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_Class = PACKid_$metamodel$.getClassId("Class", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_ClassCS = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS.getClassId("ClassCS", 0);
@@ -108,8 +113,10 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_Model = PACKid_http_c_s_s_www_eclipse_org_s_qvt_s_2015_s_QVTbaseLibrary.getClassId("Model", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_NameExpCS = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS.getClassId("NameExpCS", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_NamedElement = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("NamedElement", 0);
+ public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_NavigationExpCS = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS.getClassId("NavigationExpCS", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_OCLExpression = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("OCLExpression", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_OclElement = PACKid_$metamodel$.getClassId("OclElement", 0);
+ public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_OpaqueExpression = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("OpaqueExpression", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_Operation = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("Operation", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_OperationCS = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCLCS.getClassId("OperationCS", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_Package = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("Package", 0);
@@ -130,6 +137,7 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull ClassId CLSSid_Visitable = PACKid_http_c_s_s_www_eclipse_org_s_qvtd_s_doc_s_MiniOCL_s_1_0.getClassId("Visitable", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull DataTypeId DATAid_EString = PACKid_http_c_s_s_www_eclipse_org_s_emf_s_2002_s_Ecore.getDataTypeId("EString", 0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue INT_1 = ValueUtil.integerValueOf("1");
+ public static final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.NonNull String STR_OCL = "OCL";
public static final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.NonNull String STR_self = "self";
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId ORD_CLSSid_Class = TypeId.ORDERED_SET.getSpecializedId(CLSSid_Class_0);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId ORD_CLSSid_ClassCS = TypeId.ORDERED_SET.getSpecializedId(CLSSid_ClassCS);
@@ -142,6 +150,7 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId ORD_CLSSid_PathElementCS = TypeId.ORDERED_SET.getSpecializedId(CLSSid_PathElementCS);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId ORD_CLSSid_Property = TypeId.ORDERED_SET.getSpecializedId(CLSSid_Property);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId ORD_CLSSid_PropertyCS = TypeId.ORDERED_SET.getSpecializedId(CLSSid_PropertyCS);
+ public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull PropertyId PROPid_language = CLSSid_OpaqueExpression.getPropertyId("language");
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull PropertyId PROPid_name = CLSSid_NamedElement.getPropertyId("name");
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull PropertyId PROPid_ownedBody = CLSSid_ExpressionInOCL.getPropertyId("ownedBody");
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull PropertyId PROPid_ownedSelfVar = CLSSid_ExpressionInOCL.getPropertyId("ownedSelfVar");
@@ -155,6 +164,7 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_CallExpCS = TypeId.SET.getSpecializedId(CLSSid_CallExpCS);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_ClassCS = TypeId.SET.getSpecializedId(CLSSid_ClassCS);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_NameExpCS = TypeId.SET.getSpecializedId(CLSSid_NameExpCS);
+ public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_NavigationExpCS = TypeId.SET.getSpecializedId(CLSSid_NavigationExpCS);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_OperationCS = TypeId.SET.getSpecializedId(CLSSid_OperationCS);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_PackageCS = TypeId.SET.getSpecializedId(CLSSid_PackageCS);
public static final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull CollectionTypeId SET_CLSSid_ParameterCS = TypeId.SET.getSpecializedId(CLSSid_ParameterCS);
@@ -168,11 +178,12 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
CLSSid_CallExpCS, // 0 => CallExpCS
CLSSid_ClassCS, // 1 => ClassCS
CLSSid_NameExpCS, // 2 => NameExpCS
- CLSSid_OperationCS, // 3 => OperationCS
- CLSSid_PackageCS, // 4 => PackageCS
- CLSSid_ParameterCS, // 5 => ParameterCS
- CLSSid_PropertyCS, // 6 => PropertyCS
- CLSSid_RootCS // 7 => RootCS
+ CLSSid_NavigationExpCS, // 3 => NavigationExpCS
+ CLSSid_OperationCS, // 4 => OperationCS
+ CLSSid_PackageCS, // 5 => PackageCS
+ CLSSid_ParameterCS, // 6 => ParameterCS
+ CLSSid_PropertyCS, // 7 => PropertyCS
+ CLSSid_RootCS // 8 => RootCS
};
/*
@@ -184,12 +195,13 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
private final static int @NonNull [] @NonNull [] classIndex2allClassIndexes = new int @NonNull [] @NonNull [] {
{0}, // 0 : CallExpCS -> {CallExpCS}
{1}, // 1 : ClassCS -> {ClassCS}
- {2,0}, // 2 : NameExpCS -> {NameExpCS,CallExpCS}
- {3}, // 3 : OperationCS -> {OperationCS}
- {4}, // 4 : PackageCS -> {PackageCS}
- {5}, // 5 : ParameterCS -> {ParameterCS}
- {6}, // 6 : PropertyCS -> {PropertyCS}
- {7} // 7 : RootCS -> {RootCS}
+ {2,3,0}, // 2 : NameExpCS -> {NameExpCS,NavigationExpCS,CallExpCS}
+ {3}, // 3 : NavigationExpCS -> {NavigationExpCS}
+ {4}, // 4 : OperationCS -> {OperationCS}
+ {5}, // 5 : PackageCS -> {PackageCS}
+ {6}, // 6 : ParameterCS -> {ParameterCS}
+ {7}, // 7 : PropertyCS -> {PropertyCS}
+ {8} // 8 : RootCS -> {RootCS}
};
protected final @NonNull AbstractInvocationConstructor CTOR_m_NameExpCS_ast_1 = new AbstractInvocationConstructor(idResolver)
@@ -224,22 +236,6 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
}
};
- protected final @NonNull AbstractInvocationConstructor CTOR_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr = new AbstractInvocationConstructor(idResolver)
- {
- @Override
- public @NonNull MAP_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr newInstance(@NonNull Object @NonNull [] values) {
- return new MAP_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr(values);
- }
- };
-
- protected final @NonNull AbstractInvocationConstructor CTOR_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi = new AbstractInvocationConstructor(idResolver)
- {
- @Override
- public @NonNull MAP_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi newInstance(@NonNull Object @NonNull [] values) {
- return new MAP_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi(values);
- }
- };
-
private final MiniOCLLookupSolver lookupSolver = new MiniOCLLookupSolver(executor);
public MiniOCLCS2AS_qvtp_qvtcas(final @NonNull Executor executor) {
super(executor, new @NonNull String[] {"leftCS", "rightAS"}, null, classIndex2classId, classIndex2allClassIndexes);
@@ -266,217 +262,241 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
* in qualifier?.lookupQualifiedPackage(segments->last())
* endif
*/
- public /*@NonInvalid*/ Package lookupPackage(final /*@NonInvalid*/ org.eclipse.qvtd.doc.miniocl.util.@org.eclipse.jdt.annotation.NonNull Visitable self_0, final /*@NonInvalid*/ List<PathElementCS> segments) {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments);
- final /*@NonInvalid*/ boolean eq = size.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package symbol_1;
- if (eq) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments);
- if (aPathElementCS == null) {
- throw new InvalidValueException("Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<Package> _lookupResult = lookupSolver._lookupUnqualifiedPackage(self_0, (String)elementName);
- Package _lookupUnqualifiedPackage = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedPackage = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- symbol_1 = _lookupUnqualifiedPackage;
- }
- else {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments, INT_1, diff);
- final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
- assert UNBOXED_qualifierSegments != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = this.lookupPackage(self_0, UNBOXED_qualifierSegments);
- /*@Caught*/ @Nullable Object CAUGHT_qualifier;
- try {
- CAUGHT_qualifier = qualifier;
- }
- catch (Exception e) {
- CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
- }
- final /*@NonInvalid*/ @NonNull Object symbol_0 = CAUGHT_qualifier == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package safe_lookupQualifiedPackage_source;
- if (symbol_0 == Boolean.TRUE) {
- safe_lookupQualifiedPackage_source = null;
- }
- else {
- if (qualifier == null) {
- throw new InvalidValueException("Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments);
- if (aPathElementCS_0 == null) {
+ protected class CACHE_Visitable_lookupPackage extends AbstractEvaluationOperation
+ {
+ @Override
+ public Object basicEvaluate(@NonNull Executor executor, @NonNull TypedElement caller, @Nullable Object @NonNull [] sourceAndArgumentValues) {
+ @SuppressWarnings("null") final /*@NonInvalid*/ org.eclipse.qvtd.doc.miniocl.util.@org.eclipse.jdt.annotation.NonNull Visitable self_0 = (/*@NonInvalid*/ org.eclipse.qvtd.doc.miniocl.util.@org.eclipse.jdt.annotation.NonNull Visitable)sourceAndArgumentValues[0];
+ @SuppressWarnings("unchecked") final /*@NonInvalid*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments = (/*@NonInvalid*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS>)sourceAndArgumentValues[1];
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments);
+ final /*@NonInvalid*/ boolean eq = size.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package symbol_1;
+ if (eq) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments);
+ if (aPathElementCS == null) {
throw new InvalidValueException("Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<Package> _lookupResult_0 = lookupSolver._lookupQualifiedPackage(qualifier, (String)elementName_0);
- Package _lookupQualifiedPackage = null;
- if (_lookupResult_0.size() == 1) {
- _lookupQualifiedPackage = _lookupResult_0.getSingleResult();
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<Package> _lookupResult = lookupSolver._lookupUnqualifiedPackage(self_0, (String)elementName);
+ Package _lookupUnqualifiedPackage = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedPackage = _lookupResult.getSingleResult();
} else {
- handleLookupError(aPathElementCS_0,elementName_0);
+ handleLookupError(aPathElementCS,elementName);
};
- safe_lookupQualifiedPackage_source = _lookupQualifiedPackage;
+ symbol_1 = _lookupUnqualifiedPackage;
+ }
+ else {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments, INT_1, diff);
+ final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
+ assert UNBOXED_qualifierSegments != null;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = INST_Visitable_lookupPackage.evaluate(self_0, UNBOXED_qualifierSegments);
+ /*@Caught*/ @Nullable Object CAUGHT_qualifier;
+ try {
+ CAUGHT_qualifier = qualifier;
+ }
+ catch (Exception e) {
+ CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
+ }
+ final /*@NonInvalid*/ @NonNull Object symbol_0 = CAUGHT_qualifier == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package safe_lookupQualifiedPackage_source;
+ if (symbol_0 == Boolean.TRUE) {
+ safe_lookupQualifiedPackage_source = null;
+ }
+ else {
+ if (qualifier == null) {
+ throw new InvalidValueException("Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments);
+ if (aPathElementCS_0 == null) {
+ throw new InvalidValueException("Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
+ MiniOCLLookupResult<Package> _lookupResult_0 = lookupSolver._lookupQualifiedPackage(qualifier, (String)elementName_0);
+ Package _lookupQualifiedPackage = null;
+ if (_lookupResult_0.size() == 1) {
+ _lookupQualifiedPackage = _lookupResult_0.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS_0,elementName_0);
+ };
+ safe_lookupQualifiedPackage_source = _lookupQualifiedPackage;
+ }
+ symbol_1 = safe_lookupQualifiedPackage_source;
}
- symbol_1 = safe_lookupQualifiedPackage_source;
+ return symbol_1;
+ }
+
+ public Package evaluate(final /*@NonInvalid*/ org.eclipse.qvtd.doc.miniocl.util.@org.eclipse.jdt.annotation.NonNull Visitable self_0, final /*@NonInvalid*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments) {
+ return (Package)evaluationCache.getCachedEvaluationResult(this, caller, new @Nullable Object[]{self_0, segments});
}
- return symbol_1;
}
+ protected final @NonNull CACHE_Visitable_lookupPackage INST_Visitable_lookupPackage = new CACHE_Visitable_lookupPackage();
+
/**
*
* map __root__ in MiniOCLCS2AS_qvtp_qvtcas {
- * where ( |)
- * {_'\u00ABCallExpCS\u00BB' : Set(minioclcs::CallExpCS) = leftCS.objectsOfKind(minioclcs::CallExpCS)
+ *
+ * var _'\u00ABCallExpCS\u00BB' : Set(minioclcs::CallExpCS) := leftCS.objectsOfKind(minioclcs::CallExpCS)
+ * ;
+ * ::ji_CallExpCS : Set(minioclcs::CallExpCS)[*|1]var _'\u00ABClassCS\u00BB' : Set(minioclcs::ClassCS) := leftCS.objectsOfKind(minioclcs::ClassCS)
* ;
- * _'\u00ABClassCS\u00BB' : Set(minioclcs::ClassCS) = leftCS.objectsOfKind(minioclcs::ClassCS)
+ * ::ji_ClassCS : Set(minioclcs::ClassCS)[*|1]var _'\u00ABNameExpCS\u00BB' : Set(minioclcs::NameExpCS) := leftCS.objectsOfKind(minioclcs::NameExpCS)
* ;
- * _'\u00ABNameExpCS\u00BB' : Set(minioclcs::NameExpCS) = leftCS.objectsOfKind(minioclcs::NameExpCS)
+ * ::ji_NameExpCS : Set(minioclcs::NameExpCS)[*|1]var _'\u00ABNavigationExpCS\u00BB' : Set(minioclcs::NavigationExpCS) := leftCS.objectsOfKind(minioclcs::NavigationExpCS)
* ;
- * _'\u00ABOperationCS\u00BB' : Set(minioclcs::OperationCS) = leftCS.objectsOfKind(minioclcs::OperationCS)
+ * ::ji_NavigationExpCS : Set(minioclcs::NavigationExpCS)[*|1]var _'\u00ABOperationCS\u00BB' : Set(minioclcs::OperationCS) := leftCS.objectsOfKind(minioclcs::OperationCS)
* ;
- * _'\u00ABPackageCS\u00BB' : Set(minioclcs::PackageCS) = leftCS.objectsOfKind(minioclcs::PackageCS)
+ * ::ji_OperationCS : Set(minioclcs::OperationCS)[*|1]var _'\u00ABPackageCS\u00BB' : Set(minioclcs::PackageCS) := leftCS.objectsOfKind(minioclcs::PackageCS)
* ;
- * _'\u00ABParameterCS\u00BB' : Set(minioclcs::ParameterCS) = leftCS.objectsOfKind(minioclcs::ParameterCS)
+ * ::ji_PackageCS : Set(minioclcs::PackageCS)[*|1]var _'\u00ABParameterCS\u00BB' : Set(minioclcs::ParameterCS) := leftCS.objectsOfKind(minioclcs::ParameterCS)
* ;
- * _'\u00ABPropertyCS\u00BB' : Set(minioclcs::PropertyCS) = leftCS.objectsOfKind(minioclcs::PropertyCS)
+ * ::ji_ParameterCS : Set(minioclcs::ParameterCS)[*|1]var _'\u00ABPropertyCS\u00BB' : Set(minioclcs::PropertyCS) := leftCS.objectsOfKind(minioclcs::PropertyCS)
* ;
- * _'\u00ABRootCS\u00BB' : Set(minioclcs::RootCS) = leftCS.objectsOfKind(minioclcs::RootCS)
+ * ::ji_PropertyCS : Set(minioclcs::PropertyCS)[*|1]var _'\u00ABRootCS\u00BB' : Set(minioclcs::RootCS) := leftCS.objectsOfKind(minioclcs::RootCS)
* ;
- * ji_CallExpCS_1 : Set(minioclcs::CallExpCS)[*|1] = _'\u00ABCallExpCS\u00BB';
- * ji_ClassCS : Set(minioclcs::ClassCS)[*|1] = _'\u00ABClassCS\u00BB';
- * ji_NameExpCS : Set(minioclcs::NameExpCS)[*|1] = _'\u00ABNameExpCS\u00BB';
- * ji_OperationCS : Set(minioclcs::OperationCS)[*|1] = _'\u00ABOperationCS\u00BB';
- * ji_PackageCS : Set(minioclcs::PackageCS)[*|1] = _'\u00ABPackageCS\u00BB';
- * ji_ParameterCS : Set(minioclcs::ParameterCS)[*|1] = _'\u00ABParameterCS\u00BB';
- * ji_PropertyCS : Set(minioclcs::PropertyCS)[*|1] = _'\u00ABPropertyCS\u00BB';
- * ji_RootCS : Set(minioclcs::RootCS)[*|1] = _'\u00ABRootCS\u00BB';
- * |}
- * for loop0 : minioclcs::ClassCS in ji_ClassCS {
+ * ::ji_RootCS : Set(minioclcs::RootCS)[*|1]for loop0 : minioclcs::ClassCS[1] in ji_ClassCS {
* call m_Class_ClassCS {
- * lClassCS := loop0;
+ * lClassCS iterates loop0 : minioclcs::ClassCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
- * call m_PropertyCallExp_NameExpCS {
- * lNameExpCS := loop0;
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
+ * call m_PropertyCallExp_NameExpCS_Boolean {
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::OperationCS in ji_OperationCS {
+ * for loop0 : minioclcs::OperationCS[1] in ji_OperationCS {
* call m_Operation_OperationCS {
- * lOperationCS := loop0;
+ * lOperationCS iterates loop0 : minioclcs::OperationCS[1];
* }}
- * for loop0 : minioclcs::PackageCS in ji_PackageCS {
+ * for loop0 : minioclcs::PackageCS[1] in ji_PackageCS {
* call m_Package_PackageCS {
- * lPackageCS := loop0;
+ * lPackageCS iterates loop0 : minioclcs::PackageCS[1];
* }}
- * for loop0 : minioclcs::ParameterCS in ji_ParameterCS {
+ * for loop0 : minioclcs::ParameterCS[1] in ji_ParameterCS {
* call m_Parameter_ParameterCS {
- * lParameterCS := loop0;
+ * lParameterCS iterates loop0 : minioclcs::ParameterCS[1];
* }}
- * for loop0 : minioclcs::PropertyCS in ji_PropertyCS {
+ * for loop0 : minioclcs::PropertyCS[1] in ji_PropertyCS {
* call m_Property_PropertyCS {
- * lPropertyCS := loop0;
+ * lPropertyCS iterates loop0 : minioclcs::PropertyCS[1];
* }}
- * for loop0 : minioclcs::RootCS in ji_RootCS {
+ * for loop0 : minioclcs::RootCS[1] in ji_RootCS {
* call m_Root_RootCS {
- * lRootCS := loop0;
+ * lRootCS iterates loop0 : minioclcs::RootCS[1];
+ * }}
+ * for loop0 : minioclcs::ClassCS[1] in ji_ClassCS {
+ * call m_ClassCS_ast_name {
+ * lClassCS iterates loop0 : minioclcs::ClassCS[1];
+ * }}
+ * for loop0 : minioclcs::ClassCS[1] in ji_ClassCS {
+ * call m_ClassCS_ast_operations {
+ * lClassCS iterates loop0 : minioclcs::ClassCS[1];
* }}
- * for loop0 : minioclcs::ClassCS in ji_ClassCS {
- * call m_OrderedSet_ClassCS_2 {
- * lClassCS := loop0;
+ * for loop0 : minioclcs::ClassCS[1] in ji_ClassCS {
+ * call m_ClassCS_ast_properties {
+ * lClassCS iterates loop0 : minioclcs::ClassCS[1];
* }}
- * for loop0 : minioclcs::OperationCS in ji_OperationCS {
- * call m_OrderedSet_OperationCS_1 {
- * lOperationCS := loop0;
+ * for loop0 : minioclcs::NavigationExpCS[1] in ji_NavigationExpCS {
+ * call m_NavigationExpCS_ast0 {
+ * lNavigationExpCS iterates loop0 : minioclcs::NavigationExpCS[1];
* }}
- * for loop0 : minioclcs::PackageCS in ji_PackageCS {
- * call m_OrderedSet_PackageCS_2 {
- * lPackageCS := loop0;
+ * for loop0 : minioclcs::OperationCS[1] in ji_OperationCS {
+ * call m_OperationCS_ast_name {
+ * lOperationCS iterates loop0 : minioclcs::OperationCS[1];
* }}
- * for loop0 : minioclcs::ParameterCS in ji_ParameterCS {
- * call m_String_ParameterCS {
- * lParameterCS := loop0;
+ * for loop0 : minioclcs::OperationCS[1] in ji_OperationCS {
+ * call m_OperationCS_ast_params {
+ * lOperationCS iterates loop0 : minioclcs::OperationCS[1];
* }}
- * for loop0 : minioclcs::PropertyCS in ji_PropertyCS {
- * call m_String_PropertyCS {
- * lPropertyCS := loop0;
+ * for loop0 : minioclcs::PackageCS[1] in ji_PackageCS {
+ * call m_PackageCS_ast_name {
+ * lPackageCS iterates loop0 : minioclcs::PackageCS[1];
* }}
- * for loop0 : minioclcs::RootCS in ji_RootCS {
- * call m_OrderedSet_RootCS {
- * lRootCS := loop0;
+ * for loop0 : minioclcs::PackageCS[1] in ji_PackageCS {
+ * call m_PackageCS_ast_classes {
+ * lPackageCS iterates loop0 : minioclcs::PackageCS[1];
* }}
- * for loop0 : minioclcs::ClassCS in ji_ClassCS {
- * call m_ClassCS_ast_extends {
- * lClassCS := loop0;
+ * for loop0 : minioclcs::PackageCS[1] in ji_PackageCS {
+ * call m_PackageCS_ast_packages {
+ * lPackageCS iterates loop0 : minioclcs::PackageCS[1];
* }}
- * for loop0 : minioclcs::OperationCS in ji_OperationCS {
+ * for loop0 : minioclcs::ParameterCS[1] in ji_ParameterCS {
+ * call m_ParameterCS_ast_name {
+ * lParameterCS iterates loop0 : minioclcs::ParameterCS[1];
+ * }}
+ * for loop0 : minioclcs::PropertyCS[1] in ji_PropertyCS {
+ * call m_PropertyCS_ast_name {
+ * lPropertyCS iterates loop0 : minioclcs::PropertyCS[1];
+ * }}
+ * for loop0 : minioclcs::RootCS[1] in ji_RootCS {
+ * call m_RootCS_ast_packages {
+ * lRootCS iterates loop0 : minioclcs::RootCS[1];
+ * }}
+ * for loop0 : minioclcs::OperationCS[1] in ji_OperationCS {
* call m_OperationCS_ast_resultRef {
- * lOperationCS := loop0;
+ * lOperationCS iterates loop0 : minioclcs::OperationCS[1];
* }}
- * for loop0 : minioclcs::ParameterCS in ji_ParameterCS {
+ * for loop0 : minioclcs::ParameterCS[1] in ji_ParameterCS {
* call m_ParameterCS_ast_typeRef {
- * lParameterCS := loop0;
+ * lParameterCS iterates loop0 : minioclcs::ParameterCS[1];
* }}
- * for loop0 : minioclcs::PropertyCS in ji_PropertyCS {
+ * for loop0 : minioclcs::PropertyCS[1] in ji_PropertyCS {
* call m_PropertyCS_ast_typeRef {
- * lPropertyCS := loop0;
+ * lPropertyCS iterates loop0 : minioclcs::PropertyCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
- * call m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr {
- * lNameExpCS := loop0;
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
+ * call m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El {
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
- * call m_VariableExp_NameExpCS_CallExpCS_Element_Expressi {
- * lNameExpCS := loop0;
+ * for loop0 : minioclcs::CallExpCS[1] in ji_CallExpCS {
+ * call m_CallExpCS_ast_navExp {
+ * lCallExpCS iterates loop0 : minioclcs::CallExpCS[1];
* }}
- * for loop0 : minioclcs::CallExpCS in ji_CallExpCS_1 {
- * call m_CallExpCS_ast_nameExp {
- * lCallExpCS := loop0;
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
+ * call m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen {
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_2 {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_expName_2 {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_4 {
- * lNameExpCS := loop0;
- * }}
- * for loop0 : minioclcs::OperationCS in ji_OperationCS {
- * call m_OperationCS_ast_body {
- * lOperationCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_expName {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_1 {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_expName_1 {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
* }}
- * for loop0 : minioclcs::NameExpCS in ji_NameExpCS {
+ * for loop0 : minioclcs::NameExpCS[1] in ji_NameExpCS {
* call m_NameExpCS_ast_3 {
- * lNameExpCS := loop0;
+ * lNameExpCS iterates loop0 : minioclcs::NameExpCS[1];
+ * }}
+ * for loop0 : minioclcs::OperationCS[1] in ji_OperationCS {
+ * call m_OperationCS_ast_body {
+ * lOperationCS iterates loop0 : minioclcs::OperationCS[1];
* }}
*/
protected boolean MAP___root__() {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_1 = idResolver.getClass(CLSSid_CallExpCS, null);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_CallExpCS, models[0/*leftCS*/], TYP_minioclcs_c_c_CallExpCS_1);
@@ -484,55 +504,61 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_0 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_ClassCS, models[0/*leftCS*/], TYP_minioclcs_c_c_ClassCS_0);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_NameExpCS_0 = idResolver.getClass(CLSSid_NameExpCS, null);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_1 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_NameExpCS, models[0/*leftCS*/], TYP_minioclcs_c_c_NameExpCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_NavigationExpCS_1 = idResolver.getClass(CLSSid_NavigationExpCS, null);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_2 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_NavigationExpCS, models[0/*leftCS*/], TYP_minioclcs_c_c_NavigationExpCS_1);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_OperationCS_0 = idResolver.getClass(CLSSid_OperationCS, null);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_2 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_OperationCS, models[0/*leftCS*/], TYP_minioclcs_c_c_OperationCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_3 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_OperationCS, models[0/*leftCS*/], TYP_minioclcs_c_c_OperationCS_0);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_PackageCS_0 = idResolver.getClass(CLSSid_PackageCS, null);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_3 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_PackageCS, models[0/*leftCS*/], TYP_minioclcs_c_c_PackageCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_4 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_PackageCS, models[0/*leftCS*/], TYP_minioclcs_c_c_PackageCS_0);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_ParameterCS_0 = idResolver.getClass(CLSSid_ParameterCS, null);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_4 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_ParameterCS, models[0/*leftCS*/], TYP_minioclcs_c_c_ParameterCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_5 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_ParameterCS, models[0/*leftCS*/], TYP_minioclcs_c_c_ParameterCS_0);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_PropertyCS_0 = idResolver.getClass(CLSSid_PropertyCS, null);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_5 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_PropertyCS, models[0/*leftCS*/], TYP_minioclcs_c_c_PropertyCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_6 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_PropertyCS, models[0/*leftCS*/], TYP_minioclcs_c_c_PropertyCS_0);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_RootCS_0 = idResolver.getClass(CLSSid_RootCS, null);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_6 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_RootCS, models[0/*leftCS*/], TYP_minioclcs_c_c_RootCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SetValue objectsOfKind_7 = ModelObjectsOfKindOperation.INSTANCE.evaluate(executor, SET_CLSSid_RootCS, models[0/*leftCS*/], TYP_minioclcs_c_c_RootCS_0);
// connection variables
- final SetValue.@NonNull Accumulator ji_CallExpCS_1 = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_CallExpCS);
+ final SetValue.@NonNull Accumulator ji_CallExpCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_CallExpCS);
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS iterator : ValueUtil.typedIterable(CallExpCS.class, objectsOfKind)) {
- ji_CallExpCS_1.add(iterator);
+ ji_CallExpCS.add(iterator);
}
- final SetValue.@NonNull Accumulator ji_ClassCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_ClassCS);
+ final SetValue.@NonNull Accumulator ji_ClassCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_ClassCS);
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS iterator_0 : ValueUtil.typedIterable(ClassCS.class, objectsOfKind_0)) {
ji_ClassCS.add(iterator_0);
}
- final SetValue.@NonNull Accumulator ji_NameExpCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_NameExpCS);
+ final SetValue.@NonNull Accumulator ji_NameExpCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_NameExpCS);
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS iterator_1 : ValueUtil.typedIterable(NameExpCS.class, objectsOfKind_1)) {
ji_NameExpCS.add(iterator_1);
}
- final SetValue.@NonNull Accumulator ji_OperationCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_OperationCS);
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS iterator_2 : ValueUtil.typedIterable(OperationCS.class, objectsOfKind_2)) {
- ji_OperationCS.add(iterator_2);
+ final SetValue.@NonNull Accumulator ji_NavigationExpCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_NavigationExpCS);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NavigationExpCS iterator_2 : ValueUtil.typedIterable(NavigationExpCS.class, objectsOfKind_2)) {
+ ji_NavigationExpCS.add(iterator_2);
}
- final SetValue.@NonNull Accumulator ji_PackageCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_PackageCS);
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS iterator_3 : ValueUtil.typedIterable(PackageCS.class, objectsOfKind_3)) {
- ji_PackageCS.add(iterator_3);
+ final SetValue.@NonNull Accumulator ji_OperationCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_OperationCS);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS iterator_3 : ValueUtil.typedIterable(OperationCS.class, objectsOfKind_3)) {
+ ji_OperationCS.add(iterator_3);
}
- final SetValue.@NonNull Accumulator ji_ParameterCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_ParameterCS);
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS iterator_4 : ValueUtil.typedIterable(ParameterCS.class, objectsOfKind_4)) {
- ji_ParameterCS.add(iterator_4);
+ final SetValue.@NonNull Accumulator ji_PackageCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_PackageCS);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS iterator_4 : ValueUtil.typedIterable(PackageCS.class, objectsOfKind_4)) {
+ ji_PackageCS.add(iterator_4);
}
- final SetValue.@NonNull Accumulator ji_PropertyCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_PropertyCS);
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS iterator_5 : ValueUtil.typedIterable(PropertyCS.class, objectsOfKind_5)) {
- ji_PropertyCS.add(iterator_5);
+ final SetValue.@NonNull Accumulator ji_ParameterCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_ParameterCS);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS iterator_5 : ValueUtil.typedIterable(ParameterCS.class, objectsOfKind_5)) {
+ ji_ParameterCS.add(iterator_5);
}
- final SetValue.@NonNull Accumulator ji_RootCS = (SetValue.Accumulator)ValueUtil.createCollectionAccumulatorValue(SET_CLSSid_RootCS);
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS iterator_6 : ValueUtil.typedIterable(RootCS.class, objectsOfKind_6)) {
- ji_RootCS.add(iterator_6);
+ final SetValue.@NonNull Accumulator ji_PropertyCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_PropertyCS);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS iterator_6 : ValueUtil.typedIterable(PropertyCS.class, objectsOfKind_6)) {
+ ji_PropertyCS.add(iterator_6);
+ }
+ final SetValue.@NonNull Accumulator ji_RootCS = createUnenforcedSetAccumulatorValue(SET_CLSSid_RootCS);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS iterator_7 : ValueUtil.typedIterable(RootCS.class, objectsOfKind_7)) {
+ ji_RootCS.add(iterator_7);
}
// mapping statements
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS loop0 : ValueUtil.typedIterable(ClassCS.class, ji_ClassCS)) {
MAP_m_Class_ClassCS(loop0);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_0 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- MAP_m_PropertyCallExp_NameExpCS(loop0_0);
+ MAP_m_PropertyCallExp_NameExpCS_Boolean(loop0_0);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_1 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
MAP_m_Operation_OperationCS(loop0_1);
@@ -550,70 +576,85 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
MAP_m_Root_RootCS(loop0_5);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS loop0_6 : ValueUtil.typedIterable(ClassCS.class, ji_ClassCS)) {
- MAP_m_OrderedSet_ClassCS_2(loop0_6);
+ MAP_m_ClassCS_ast_name(loop0_6);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_7 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
- MAP_m_OrderedSet_OperationCS_1(loop0_7);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS loop0_7 : ValueUtil.typedIterable(ClassCS.class, ji_ClassCS)) {
+ MAP_m_ClassCS_ast_operations(loop0_7);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS loop0_8 : ValueUtil.typedIterable(PackageCS.class, ji_PackageCS)) {
- MAP_m_OrderedSet_PackageCS_2(loop0_8);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS loop0_8 : ValueUtil.typedIterable(ClassCS.class, ji_ClassCS)) {
+ MAP_m_ClassCS_ast_properties(loop0_8);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS loop0_9 : ValueUtil.typedIterable(ParameterCS.class, ji_ParameterCS)) {
- MAP_m_String_ParameterCS(loop0_9);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NavigationExpCS loop0_9 : ValueUtil.typedIterable(NavigationExpCS.class, ji_NavigationExpCS)) {
+ MAP_m_NavigationExpCS_ast0(loop0_9);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS loop0_10 : ValueUtil.typedIterable(PropertyCS.class, ji_PropertyCS)) {
- MAP_m_String_PropertyCS(loop0_10);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_10 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
+ MAP_m_OperationCS_ast_name(loop0_10);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS loop0_11 : ValueUtil.typedIterable(RootCS.class, ji_RootCS)) {
- MAP_m_OrderedSet_RootCS(loop0_11);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_11 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
+ MAP_m_OperationCS_ast_params(loop0_11);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS loop0_12 : ValueUtil.typedIterable(ClassCS.class, ji_ClassCS)) {
- MAP_m_ClassCS_ast_extends(loop0_12);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS loop0_12 : ValueUtil.typedIterable(PackageCS.class, ji_PackageCS)) {
+ MAP_m_PackageCS_ast_name(loop0_12);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_13 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
- MAP_m_OperationCS_ast_resultRef(loop0_13);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS loop0_13 : ValueUtil.typedIterable(PackageCS.class, ji_PackageCS)) {
+ MAP_m_PackageCS_ast_classes(loop0_13);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS loop0_14 : ValueUtil.typedIterable(ParameterCS.class, ji_ParameterCS)) {
- MAP_m_ParameterCS_ast_typeRef(loop0_14);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS loop0_14 : ValueUtil.typedIterable(PackageCS.class, ji_PackageCS)) {
+ MAP_m_PackageCS_ast_packages(loop0_14);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS loop0_15 : ValueUtil.typedIterable(PropertyCS.class, ji_PropertyCS)) {
- MAP_m_PropertyCS_ast_typeRef(loop0_15);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS loop0_15 : ValueUtil.typedIterable(ParameterCS.class, ji_ParameterCS)) {
+ MAP_m_ParameterCS_ast_name(loop0_15);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_16 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- invoke(CTOR_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr, loop0_16);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS loop0_16 : ValueUtil.typedIterable(PropertyCS.class, ji_PropertyCS)) {
+ MAP_m_PropertyCS_ast_name(loop0_16);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_17 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- invoke(CTOR_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi, loop0_17);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS loop0_17 : ValueUtil.typedIterable(RootCS.class, ji_RootCS)) {
+ MAP_m_RootCS_ast_packages(loop0_17);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS loop0_18 : ValueUtil.typedIterable(CallExpCS.class, ji_CallExpCS_1)) {
- MAP_m_CallExpCS_ast_nameExp(loop0_18);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_18 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
+ MAP_m_OperationCS_ast_resultRef(loop0_18);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_19 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- MAP_m_NameExpCS_ast(loop0_19);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS loop0_19 : ValueUtil.typedIterable(ParameterCS.class, ji_ParameterCS)) {
+ MAP_m_ParameterCS_ast_typeRef(loop0_19);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_20 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- MAP_m_NameExpCS_ast_2(loop0_20);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS loop0_20 : ValueUtil.typedIterable(PropertyCS.class, ji_PropertyCS)) {
+ MAP_m_PropertyCS_ast_typeRef(loop0_20);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_21 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- MAP_m_NameExpCS_ast_expName_2(loop0_21);
+ MAP_m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El(loop0_21);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_22 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- MAP_m_NameExpCS_ast_4(loop0_22);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS loop0_22 : ValueUtil.typedIterable(CallExpCS.class, ji_CallExpCS)) {
+ MAP_m_CallExpCS_ast_navExp(loop0_22);
}
- for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_23 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
- MAP_m_OperationCS_ast_body(loop0_23);
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_23 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
+ MAP_m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen(loop0_23);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_24 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- invoke(CTOR_m_NameExpCS_ast_expName, loop0_24);
+ MAP_m_NameExpCS_ast(loop0_24);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_25 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- invoke(CTOR_m_NameExpCS_ast_1, loop0_25);
+ MAP_m_NameExpCS_ast_2(loop0_25);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_26 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- invoke(CTOR_m_NameExpCS_ast_expName_1, loop0_26);
+ MAP_m_NameExpCS_ast_expName_2(loop0_26);
}
for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_27 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
- invoke(CTOR_m_NameExpCS_ast_3, loop0_27);
+ MAP_m_NameExpCS_ast_4(loop0_27);
+ }
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_28 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
+ invoke(CTOR_m_NameExpCS_ast_expName, loop0_28);
+ }
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_29 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
+ invoke(CTOR_m_NameExpCS_ast_1, loop0_29);
+ }
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_30 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
+ invoke(CTOR_m_NameExpCS_ast_expName_1, loop0_30);
+ }
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS loop0_31 : ValueUtil.typedIterable(NameExpCS.class, ji_NameExpCS)) {
+ invoke(CTOR_m_NameExpCS_ast_3, loop0_31);
+ }
+ for (org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS loop0_32 : ValueUtil.typedIterable(OperationCS.class, ji_OperationCS)) {
+ MAP_m_OperationCS_ast_body(loop0_32);
}
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean __root__ = ValueUtil.TRUE_VALUE;
return __root__;
@@ -624,261 +665,234 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
- * map m_CallExpCS_ast_nameExp in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lCallExpCS : minioclcs::CallExpCS[1];
- * |)
- * {nameExp : minioclcs::NameExpCS[?];
- * |}
- * rightAS ( |)
- * {aOCLExpression : miniocl::OCLExpression[1];
- * ast : miniocl::Element[1];
- * |}
- * where ( |
- * lCallExpCS.oclIsTypeOf(minioclcs::CallExpCS))
- * { |
- * nameExp := lCallExpCS.nameExp;
- * aOCLExpression := nameExp.ast;
- * ast := nameExp.ast;
- * lCallExpCS.ast := aOCLExpression;
- * }
+ * map m_CallExpCS_ast_navExp in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lCallExpCS : minioclcs::CallExpCS[1];
+ * var navExp : minioclcs::NavigationExpCS[?] := lCallExpCS.navExp;
+ * check lCallExpCS.oclIsTypeOf(minioclcs::CallExpCS)
+ * ;
+ * var ast : miniocl::Element[?] := navExp.ast;
+ * var aCallExp : miniocl::CallExp[1] := ast.oclAsType(miniocl::CallExp);
+ * notify set lCallExpCS.ast := aCallExp;
*
*/
- protected boolean MAP_m_CallExpCS_ast_nameExp(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS lCallExpCS) {
+ protected boolean MAP_m_CallExpCS_ast_navExp(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS lCallExpCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = lCallExpCS.getNavExp();
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_0_0 = idResolver.getClass(CLSSid_CallExpCS, null);
final /*@NonInvalid*/ boolean oclIsTypeOf = OclAnyOclIsTypeOfOperation.INSTANCE.evaluate(executor, lCallExpCS, TYP_minioclcs_c_c_CallExpCS_0_0).booleanValue();
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_6;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_2;
if (oclIsTypeOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = lCallExpCS.getNameExp();
- if (nameExp == null) {
+ if (navExp == null) {
throw throwNull(lCallExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CSTrace::ast\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = nameExp.getAst();
- final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aOCLExpression;
- if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof OCLExpression;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_5;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable OCLExpression symbol_2 = (OCLExpression)ast;
- if (symbol_2 == null) {
- throw throwNull(lCallExpCS, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lCallExpCS, "Null where non-null value required");
- }
- // property assignments
- lCallExpCS.setAst(symbol_2);
- objectManager.assigned(lCallExpCS, MinioclcsPackage.Literals.CS_TRACE__AST, symbol_2, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_CallExpCS_ast_nameExp = ValueUtil.TRUE_VALUE;
- raw_ast = m_CallExpCS_ast_nameExp;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
- }
- symbol_5 = raw_ast;
- }
- else {
- symbol_5 = ValueUtil.FALSE_VALUE;
- }
- raw_aOCLExpression = symbol_5;
- }
- else {
- raw_aOCLExpression = ValueUtil.FALSE_VALUE;
- }
- symbol_6 = raw_aOCLExpression;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = navExp.getAst();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_CallExp_0 = idResolver.getClass(CLSSid_CallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull CallExp oclAsType = ClassUtil.nonNullState((CallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_CallExp_0));
+ // mapping statements
+ lCallExpCS.setAst(oclAsType);
+ objectManager.assigned(lCallExpCS, MinioclcsPackage.Literals.CS_TRACE__AST, oclAsType, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_CallExpCS_ast_navExp = ValueUtil.TRUE_VALUE;
+ symbol_2 = m_CallExpCS_ast_navExp;
}
else {
- symbol_6 = ValueUtil.FALSE_VALUE;
+ symbol_2 = ValueUtil.FALSE_VALUE;
}
- return symbol_6;
+ return symbol_2;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_CallExpCS_ast_nameExp", e);
+ return handleExecutionFailure("MAP_m_CallExpCS_ast_navExp", e);
}
}
/**
*
- * map m_ClassCS_ast_extends in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lClassCS : minioclcs::ClassCS[1];
- * |)
- * {extends : minioclcs::PathNameCS[?];
- * |}
- * rightAS ( |)
- * {aClass : miniocl::Class[1];
- * ast : miniocl::Element[1];
- * superClass : miniocl::Class[1];
- * |}
- * where ( |)
- * {_'=' : Boolean[1];
- * |
- * aClass := lClassCS.ast;
- * ast := lClassCS.ast;
- * extends := lClassCS.extends;
- * _'=' := extends =
- * null;
- * superClass := if _'='
- * then null
- * else aClass.lookupClass(extends)
- * endif;
- * aClass.superClass := superClass;
- * }
+ * map m_ClassCS_ast_name in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lClassCS : minioclcs::ClassCS[1];
+ * var ast : miniocl::Element[1] := lClassCS.ast;
+ * var name : ecore::EString[?] := lClassCS.name;
+ * var aClass : miniocl::Class[1] := ast.oclAsType(miniocl::Class)
+ * ;
+ * set aClass.name := name.toString();
*
*/
- protected boolean MAP_m_ClassCS_ast_extends(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS) {
+ protected boolean MAP_m_ClassCS_ast_name(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lClassCS.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aClass;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof org.eclipse.qvtd.doc.miniocl.Class;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_11;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_2 = (org.eclipse.qvtd.doc.miniocl.Class)ast;
- if (symbol_2 == null) {
- throw throwNull(lClassCS, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lClassCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS symbol_4 = lClassCS.getExtends();
- final /*@Thrown*/ boolean symbol_5 = symbol_4 == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_8;
- if (symbol_5) {
- symbol_8 = null;
- }
- else {
- if (symbol_4 == null) {
- throw throwNull(lClassCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = symbol_4.getPathElements();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
- final /*@Thrown*/ boolean eq = size.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_7;
- if (eq) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS == null) {
- throw throwNull(lClassCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(symbol_2, (String)elementName);
- org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedClass = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- symbol_7 = _lookupUnqualifiedClass;
- }
- else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
- final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
- assert UNBOXED_qualifierSegments != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = this.lookupPackage(symbol_2, UNBOXED_qualifierSegments);
- /*@Caught*/ @Nullable Object CAUGHT_qualifier;
- try {
- CAUGHT_qualifier = qualifier;
- }
- catch (Exception e) {
- CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
- }
- final /*@NonInvalid*/ @NonNull Object symbol_6 = CAUGHT_qualifier == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
- if (symbol_6 == Boolean.TRUE) {
- safe_lookupQualifiedClass_source = null;
- }
- else {
- if (qualifier == null) {
- throw throwNull(lClassCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_0 == null) {
- throw throwNull(lClassCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
- org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
- if (_lookupResult_0.size() == 1) {
- _lookupQualifiedClass = _lookupResult_0.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_0,elementName_0);
- };
- safe_lookupQualifiedClass_source = _lookupQualifiedClass;
- }
- symbol_7 = safe_lookupQualifiedClass_source;
- }
- symbol_8 = symbol_7;
- }
- final /*@Thrown*/ boolean symbol_9 = symbol_8 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_superClass;
- if (symbol_9) {
- if (symbol_8 == null) {
- throw throwNull(lClassCS, "Null where non-null value required");
- }
- // property assignments
- symbol_2.setSuperClass(symbol_8);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ClassCS_ast_extends = ValueUtil.TRUE_VALUE;
- raw_superClass = m_ClassCS_ast_extends;
- }
- else {
- raw_superClass = ValueUtil.FALSE_VALUE;
- }
- raw_ast = raw_superClass;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (ast == null) {
+ throw throwNull(lClassCS, "Null where non-null value required");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lClassCS.getName();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Class_0 = idResolver.getClass(CLSSid_Class_0, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class oclAsType = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Class)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Class_0));
+ // mapping statements
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
+ oclAsType.setName(toString);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ClassCS_ast_name = ValueUtil.TRUE_VALUE;
+ raw_ast = m_ClassCS_ast_name;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_ClassCS_ast_name", e);
+ }
+ }
+
+ /**
+ *
+ * map m_ClassCS_ast_operations in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lClassCS : minioclcs::ClassCS[1];
+ * var ast : miniocl::Element[1] := lClassCS.ast;
+ * var operations : OrderedSet(minioclcs::OperationCS)[*|1] := lClassCS.operations;
+ * var aClass : miniocl::Class[1] := ast.oclAsType(miniocl::Class)
+ * ;
+ * var _'\u00ABcollect\u00BB' : Sequence(miniocl::Operation)[*|1] := operations->collect(_'1_' |
+ * _'1_'.ast.oclAsType(miniocl::Operation))
+ * ;
+ * var asOrderedSet : OrderedSet(miniocl::Operation)[*|1] := _'\u00ABcollect\u00BB'->asOrderedSet();
+ * set aClass.ownedOperations := asOrderedSet;
+ *
+ */
+ protected boolean MAP_m_ClassCS_ast_operations(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS_0) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lClassCS_0.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lClassCS_0, "Null where non-null value required");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<OperationCS> operations = lClassCS_0.getOperations();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Class_0 = idResolver.getClass(CLSSid_Class_0, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class oclAsType = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Class)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Class_0));
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_operations = idResolver.createOrderedSetOfAll(ORD_CLSSid_OperationCS, operations);
+ /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Operation);
+ @NonNull Iterator<Object> ITERATOR__1 = BOXED_operations.iterator();
+ /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
+ while (true) {
+ if (!ITERATOR__1.hasNext()) {
+ collect = accumulator;
+ break;
}
- symbol_11 = raw_ast;
+ @SuppressWarnings("null")
+ /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS _1 = (OperationCS)ITERATOR__1.next();
+ /**
+ * _'1_'.ast.oclAsType(miniocl::Operation)
+ */
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Operation_0 = idResolver.getClass(CLSSid_Operation, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = _1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Operation oclAsType_0 = ClassUtil.nonNullState((Operation)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_Operation_0));
+ //
+ accumulator.add(oclAsType_0);
}
- else {
- symbol_11 = ValueUtil.FALSE_VALUE;
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
+ // mapping statements
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Operation> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Operation.class, asOrderedSet);
+ oclAsType.getOwnedOperations().addAll(ECORE_asOrderedSet);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ClassCS_ast_operations = ValueUtil.TRUE_VALUE;
+ raw_ast = m_ClassCS_ast_operations;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_ClassCS_ast_operations", e);
+ }
+ }
+
+ /**
+ *
+ * map m_ClassCS_ast_properties in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lClassCS : minioclcs::ClassCS[1];
+ * var ast : miniocl::Element[1] := lClassCS.ast;
+ * var properties : OrderedSet(minioclcs::PropertyCS)[*|1] := lClassCS.properties;
+ * var aClass : miniocl::Class[1] := ast.oclAsType(miniocl::Class)
+ * ;
+ * var _'\u00ABcollect\u00BB' : Sequence(miniocl::Property)[*|1] := properties->collect(_'1_' |
+ * _'1_'.ast.oclAsType(miniocl::Property))
+ * ;
+ * var asOrderedSet : OrderedSet(miniocl::Property)[*|1] := _'\u00ABcollect\u00BB'->asOrderedSet();
+ * set aClass.ownedProperties := asOrderedSet;
+ *
+ */
+ protected boolean MAP_m_ClassCS_ast_properties(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS_1) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lClassCS_1.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lClassCS_1, "Null where non-null value required");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PropertyCS> properties = lClassCS_1.getProperties();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Class_0 = idResolver.getClass(CLSSid_Class_0, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class oclAsType = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Class)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Class_0));
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_properties = idResolver.createOrderedSetOfAll(ORD_CLSSid_PropertyCS, properties);
+ /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Property);
+ @NonNull Iterator<Object> ITERATOR__1 = BOXED_properties.iterator();
+ /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
+ while (true) {
+ if (!ITERATOR__1.hasNext()) {
+ collect = accumulator;
+ break;
+ }
+ @SuppressWarnings("null")
+ /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS _1 = (PropertyCS)ITERATOR__1.next();
+ /**
+ * _'1_'.ast.oclAsType(miniocl::Property)
+ */
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Property_0 = idResolver.getClass(CLSSid_Property, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = _1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property oclAsType_0 = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Property)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_Property_0));
+ //
+ accumulator.add(oclAsType_0);
}
- raw_aClass = symbol_11;
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
+ // mapping statements
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<org.eclipse.qvtd.doc.miniocl.Property> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(org.eclipse.qvtd.doc.miniocl.Property.class, asOrderedSet);
+ oclAsType.getOwnedProperties().addAll(ECORE_asOrderedSet);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ClassCS_ast_properties = ValueUtil.TRUE_VALUE;
+ raw_ast = m_ClassCS_ast_properties;
}
else {
- raw_aClass = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aClass;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_ClassCS_ast_extends", e);
+ return handleExecutionFailure("MAP_m_ClassCS_ast_properties", e);
}
}
/**
*
- * map m_Class_ClassCS in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lClassCS : minioclcs::ClassCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rClass : miniocl::Class[1];
- * |}
- * where ( |)
- * { |
- * lClassCS.ast := rClass;
- * }
+ * map m_Class_ClassCS in MiniOCLCS2AS_qvtp_qvtcas {
+ * guard:leftCS lClassCS : minioclcs::ClassCS[1];
+ * new:rightAS rClass : miniocl::Class[1];
+ * set lClassCS.ast := rClass;
*
*/
- protected boolean MAP_m_Class_ClassCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS_0) {
+ protected boolean MAP_m_Class_ClassCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS_2) {
try {
- // predicates and unrealized variables
// creations
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class rClass = MiniOCLFactory.eINSTANCE.createClass();
assert rClass != null;
models[1/*rightAS*/].add(rClass);
- // property assignments
- lClassCS_0.setAst(rClass);
+ // mapping statements
+ lClassCS_2.setAst(rClass);
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Class_ClassCS = ValueUtil.TRUE_VALUE;
return m_Class_ClassCS;
} catch (Throwable e) {
@@ -889,315 +903,315 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
* map m_NameExpCS_ast in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {aPropertyCallExp : miniocl::PropertyCallExp[1];
- * ast : miniocl::Element[1];
- * lookupVariable : miniocl::Variable[?];
- * ownedSource : miniocl::OCLExpression[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |
- * not lNameExpCS.isPropCallExpWithExplicitSource()
- * not lNameExpCS.isVariableExp()
- * lNameExpCS.isPropCallExpWithImplicitSource()
- * )
- * { |
- * aPropertyCallExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * lookupVariable := aPropertyCallExp.lookupVariable('self')
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource()
+ * ;
+ * check not lNameExpCS.isVariableExp()
* ;
- * type := lookupVariable.type;
- * ownedSource := miniocl::VariableExp{referredVariable = lookupVariable, type = type
+ * check lNameExpCS.isPropCallExpWithImplicitSource()
+ * ;
+ * var aPropertyCallExp : miniocl::PropertyCallExp[1] := ast.oclAsType(miniocl::PropertyCallExp)
+ * ;
+ * var lookupVariable : miniocl::Variable[?] := aPropertyCallExp.lookupVariable('self')
+ * ;
+ * var type : miniocl::Class[1] := lookupVariable.type;
+ * var VariableExp : miniocl::VariableExp[1] := miniocl::VariableExp{referredVariable = lookupVariable, type = type
* };
- * aPropertyCallExp.ownedSource := ownedSource;
- * }
+ * check type = lookupVariable.type;
+ * set aPropertyCallExp.ownedSource := VariableExp;
*
*/
protected boolean MAP_m_NameExpCS_ast(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS.equals(nameExp);
- symbol_1 = eq_1;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS, "Null where non-null value required");
}
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(and);
- if (not == null) {
- throw throwNull(lNameExpCS, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_17;
- if (not) {
- /*@Caught*/ @Nullable Object CAUGHT_and_1;
+ /*@Caught*/ @Nullable Object CAUGHT_and;
try {
- /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
try {
- /*@Caught*/ @NonNull Object CAUGHT_eq_2;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
- CAUGHT_eq_2 = eq_2;
- }
- catch (Exception e) {
- CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @Nullable Object CAUGHT_not_0;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_2 = oclAsType_0;
- }
- else {
- symbol_2 = null;
- }
- final /*@Thrown*/ boolean eq_3 = symbol_2 == null;
- /*@Thrown*/ boolean symbol_3;
- if (eq_3) {
- symbol_3 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_2 == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_4 = lNameExpCS.equals(nameExp_0);
- symbol_3 = eq_4;
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(symbol_3);
- CAUGHT_not_0 = not_0;
- }
- catch (Exception e) {
- CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
- CAUGHT_and_0 = and_0;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
catch (Exception e) {
- CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @NonNull Object CAUGHT_eq_5;
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS.getExpName();
- if (expName == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_1 = oclAsType;
}
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
- final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
- CAUGHT_eq_5 = eq_5;
+ else {
+ symbol_1 = null;
+ }
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
+ if (eq_0) {
+ symbol_2 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS.equals(navExp);
+ symbol_2 = eq_1;
+ }
+ CAUGHT_symbol_2 = symbol_2;
}
catch (Exception e) {
- CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
- CAUGHT_and_1 = and_1;
- }
- catch (Exception e) {
- CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_ne;
- try {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
- if (self_1 == null) {
- throw throwNull(lNameExpCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS.getExpName();
- if (expName_0 == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
- if (aPathElementCS == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
- Variable _lookupUnqualifiedVariable = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
- CAUGHT_ne = ne;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_2);
+ CAUGHT_and = and;
}
catch (Exception e) {
- CAUGHT_ne = ValueUtil.createInvalidValue(e);
+ CAUGHT_and = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(and_2);
- if (not_1 == null) {
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and);
+ if (not == null) {
throw throwNull(lNameExpCS, "Null if condition");
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_16;
- if (not_1) {
- /*@Caught*/ @NonNull Object CAUGHT_eq_6;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_6 = roundedBrackets_1 == null;
- CAUGHT_eq_6 = eq_6;
- }
- catch (Exception e) {
- CAUGHT_eq_6 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @Nullable Object CAUGHT_not_2;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_14;
+ if (not) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_2;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_1 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_6 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_1 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_4;
- if (oclIsKindOf_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_2 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6));
- symbol_4 = oclAsType_2;
- }
- else {
- symbol_4 = null;
+ /*@Caught*/ @Nullable Object CAUGHT_and_1;
+ try {
+ /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_2;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
+ CAUGHT_eq_2 = eq_2;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not_0;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_4;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_3;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_3 = oclAsType_0;
+ }
+ else {
+ symbol_3 = null;
+ }
+ final /*@Thrown*/ boolean eq_3 = symbol_3 == null;
+ /*@Thrown*/ boolean symbol_4;
+ if (eq_3) {
+ symbol_4 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_3 == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_3.getNavExp();
+ final /*@Thrown*/ boolean eq_4 = lNameExpCS.equals(navExp_0);
+ symbol_4 = eq_4;
+ }
+ CAUGHT_symbol_4 = symbol_4;
+ }
+ catch (Exception e) {
+ CAUGHT_symbol_4 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_4);
+ CAUGHT_not_0 = not_0;
+ }
+ catch (Exception e) {
+ CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
+ CAUGHT_and_0 = and_0;
+ }
+ catch (Exception e) {
+ CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_eq_5;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS.getExpName();
+ if (expName == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
+ final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
+ CAUGHT_eq_5 = eq_5;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
+ CAUGHT_and_1 = and_1;
}
- final /*@Thrown*/ boolean eq_7 = symbol_4 == null;
- /*@Thrown*/ boolean symbol_5;
- if (eq_7) {
- symbol_5 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
}
- else {
- if (symbol_4 == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ /*@Caught*/ @NonNull Object CAUGHT_ne;
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
+ if (self_1 == null) {
+ throw throwNull(lNameExpCS, "Null where non-null value required");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_1 = symbol_4.getNameExp();
- final /*@Thrown*/ boolean eq_8 = lNameExpCS.equals(nameExp_1);
- symbol_5 = eq_8;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS.getExpName();
+ if (expName_0 == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
+ Variable _lookupUnqualifiedVariable = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
+ CAUGHT_ne = ne;
+ }
+ catch (Exception e) {
+ CAUGHT_ne = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(symbol_5);
- CAUGHT_not_2 = not_2;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
+ CAUGHT_and_2 = and_2;
}
catch (Exception e) {
- CAUGHT_not_2 = ValueUtil.createInvalidValue(e);
+ CAUGHT_and_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_not_2);
- if (and_3 == null) {
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_2);
+ if (not_1 == null) {
throw throwNull(lNameExpCS, "Null if condition");
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_15;
- if (and_3) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS.getAst();
- final /*@Thrown*/ boolean symbol_6 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPropertyCallExp;
- if (symbol_6) {
- final /*@NonInvalid*/ boolean symbol_7 = ast instanceof PropertyCallExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_14;
- if (symbol_7) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp symbol_8 = (PropertyCallExp)ast;
- if (symbol_8 == null) {
- throw throwNull(lNameExpCS, "Null where non-null value required");
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_13;
+ if (not_1) {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_6;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_6 = roundedBrackets_1 == null;
+ CAUGHT_eq_6 = eq_6;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_6 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not_2;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_6;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_1 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_6 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_1 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_5;
+ if (oclIsKindOf_1) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_2 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6));
+ symbol_5 = oclAsType_2;
}
- final /*@Thrown*/ boolean symbol_9 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_9) {
- if (ast == null) {
- throw throwNull(lNameExpCS, "Null where non-null value required");
- }
- MiniOCLLookupResult<Variable> _lookupResult_0 = lookupSolver._lookupUnqualifiedVariable(symbol_8, STR_self);
- Variable _lookupUnqualifiedVariable_0 = null;
- if (_lookupResult_0.size() == 1) {
- _lookupUnqualifiedVariable_0 = _lookupResult_0.getSingleResult();
- } else {
- };
- if (_lookupUnqualifiedVariable_0 == null) {
- throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCL/1.0\'::TypedElement::type\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = _lookupUnqualifiedVariable_0.getType();
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_referredVariable = idResolver.getProperty(PROPid_referredVariable);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_type = idResolver.getProperty(PROPid_type);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_VariableExp_0 = idResolver.getClass(CLSSid_VariableExp, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull VariableExp symbol_12 = (VariableExp)TYP_miniocl_c_c_VariableExp_0.createInstance();
- CTORid_referredVariable.initValue(symbol_12, _lookupUnqualifiedVariable_0);
- CTORid_type.initValue(symbol_12, type);
- models[1/*rightAS*/].add(symbol_12);
- // property assignments
- symbol_8.setOwnedSource(symbol_12);
- objectManager.assigned(symbol_8, MiniOCLPackage.Literals.CALL_EXP__OWNED_SOURCE, symbol_12, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast = ValueUtil.TRUE_VALUE;
- raw_ast = m_NameExpCS_ast;
+ else {
+ symbol_5 = null;
+ }
+ final /*@Thrown*/ boolean eq_7 = symbol_5 == null;
+ /*@Thrown*/ boolean symbol_6;
+ if (eq_7) {
+ symbol_6 = ValueUtil.FALSE_VALUE;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (symbol_5 == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_1 = symbol_5.getNavExp();
+ final /*@Thrown*/ boolean eq_8 = lNameExpCS.equals(navExp_1);
+ symbol_6 = eq_8;
}
- symbol_14 = raw_ast;
+ CAUGHT_symbol_6 = symbol_6;
}
- else {
- symbol_14 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_symbol_6 = ValueUtil.createInvalidValue(e);
}
- raw_aPropertyCallExp = symbol_14;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_6);
+ CAUGHT_not_2 = not_2;
+ }
+ catch (Exception e) {
+ CAUGHT_not_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_not_2);
+ if (and_3 == null) {
+ throw throwNull(lNameExpCS, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_12;
+ if (and_3) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_PropertyCallExp_0 = idResolver.getClass(CLSSid_PropertyCallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull PropertyCallExp oclAsType_3 = ClassUtil.nonNullState((PropertyCallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_PropertyCallExp_0));
+ MiniOCLLookupResult<Variable> _lookupResult_0 = lookupSolver._lookupUnqualifiedVariable(oclAsType_3, STR_self);
+ Variable _lookupUnqualifiedVariable_0 = null;
+ if (_lookupResult_0.size() == 1) {
+ _lookupUnqualifiedVariable_0 = _lookupResult_0.getSingleResult();
+ } else {
+ };
+ if (_lookupUnqualifiedVariable_0 == null) {
+ throw throwNull(lNameExpCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCL/1.0\'::TypedElement::type\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = _lookupUnqualifiedVariable_0.getType();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_referredVariable = idResolver.getProperty(PROPid_referredVariable);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_type = idResolver.getProperty(PROPid_type);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_VariableExp_0 = idResolver.getClass(CLSSid_VariableExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull VariableExp symbol_9 = (VariableExp)TYP_miniocl_c_c_VariableExp_0.createInstance();
+ CTORid_referredVariable.initValue(symbol_9, _lookupUnqualifiedVariable_0);
+ CTORid_type.initValue(symbol_9, type);
+ // mapping statements
+ oclAsType_3.setOwnedSource(symbol_9);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast = ValueUtil.TRUE_VALUE;
+ symbol_12 = m_NameExpCS_ast;
}
else {
- raw_aPropertyCallExp = ValueUtil.FALSE_VALUE;
+ symbol_12 = ValueUtil.FALSE_VALUE;
}
- symbol_15 = raw_aPropertyCallExp;
+ symbol_13 = symbol_12;
}
else {
- symbol_15 = ValueUtil.FALSE_VALUE;
+ symbol_13 = ValueUtil.FALSE_VALUE;
}
- symbol_16 = symbol_15;
+ symbol_14 = symbol_13;
}
else {
- symbol_16 = ValueUtil.FALSE_VALUE;
+ symbol_14 = ValueUtil.FALSE_VALUE;
}
- symbol_17 = symbol_16;
+ raw_ast = symbol_14;
}
else {
- symbol_17 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return symbol_17;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_NameExpCS_ast", e);
}
@@ -1206,32 +1220,25 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
* map m_NameExpCS_ast_1 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {aPropertyCallExp : miniocl::PropertyCallExp[1];
- * ast : miniocl::Element[1];
- * referredProperty : miniocl::Property[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |
- * lNameExpCS.isPropCallExpWithImplicitSource()
- * not lNameExpCS.isVariableExp()
- * not lNameExpCS.isPropCallExpWithExplicitSource())
- * {_'=' : Boolean[1];
- * |
- * aPropertyCallExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * referredProperty := aPropertyCallExp.referredProperty;
- * _'=' := referredProperty =
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * check not lNameExpCS.isVariableExp()
+ * ;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource()
+ * ;
+ * check lNameExpCS.isPropCallExpWithImplicitSource()
+ * ;
+ * var aPropertyCallExp : miniocl::PropertyCallExp[1] := ast.oclAsType(miniocl::PropertyCallExp);
+ * var referredProperty : miniocl::Property[1] := aPropertyCallExp.referredProperty;
+ * var _'=' : Boolean[1] := referredProperty =
* null;
- * type := if _'='
+ * var type : miniocl::Class[1] := referredProperty.type;
+ * var _'if' : miniocl::Class[?] := if _'='
* then null
- * else referredProperty.type
+ * else type
* endif;
- * aPropertyCallExp.type := type;
- * }
+ * notify set aPropertyCallExp.type := _'if';
*
*/
protected class MAP_m_NameExpCS_ast_1 extends AbstractInvocation
@@ -1242,280 +1249,291 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
lNameExpCS_0 = (NameExpCS)boundValues[0];
}
+ @Override
public boolean execute() {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_0.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @Nullable Object CAUGHT_not;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_0.equals(nameExp);
- symbol_1 = eq_1;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_0.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS_0, "Null where non-null value required");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(symbol_1);
- CAUGHT_not = not;
- }
- catch (Exception e) {
- CAUGHT_not = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_not);
- if (and == null) {
- throw throwNull(lNameExpCS_0, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_14;
- if (and) {
/*@Caught*/ @Nullable Object CAUGHT_and_1;
try {
/*@Caught*/ @Nullable Object CAUGHT_and_0;
try {
- /*@Caught*/ @NonNull Object CAUGHT_eq_2;
+ /*@Caught*/ @Nullable Object CAUGHT_and;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_0.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
- CAUGHT_eq_2 = eq_2;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_0.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
+ }
+ catch (Exception e) {
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_1 = oclAsType;
+ }
+ else {
+ symbol_1 = null;
+ }
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
+ if (eq_0) {
+ symbol_2 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_0.equals(navExp);
+ symbol_2 = eq_1;
+ }
+ CAUGHT_symbol_2 = symbol_2;
+ }
+ catch (Exception e) {
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_2);
+ CAUGHT_not = not;
+ }
+ catch (Exception e) {
+ CAUGHT_not = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_not);
+ CAUGHT_and = and;
}
catch (Exception e) {
- CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
+ CAUGHT_and = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @Nullable Object CAUGHT_not_0;
+ /*@Caught*/ @NonNull Object CAUGHT_eq_2;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_2 = oclAsType_0;
- }
- else {
- symbol_2 = null;
- }
- final /*@Thrown*/ boolean eq_3 = symbol_2 == null;
- /*@Thrown*/ boolean symbol_3;
- if (eq_3) {
- symbol_3 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_2 == null) {
- throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_4 = lNameExpCS_0.equals(nameExp_0);
- symbol_3 = eq_4;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_0.getExpName();
+ if (expName == null) {
+ throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(symbol_3);
- CAUGHT_not_0 = not_0;
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
+ final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
+ CAUGHT_eq_2 = eq_2;
}
catch (Exception e) {
- CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
+ CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and, CAUGHT_eq_2);
CAUGHT_and_0 = and_0;
}
catch (Exception e) {
CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @NonNull Object CAUGHT_eq_5;
+ /*@Caught*/ @NonNull Object CAUGHT_ne;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_0.getExpName();
- if (expName == null) {
- throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_0 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_0.getAst();
+ if (self_1 == null) {
+ throw throwNull(lNameExpCS_0, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_0.getExpName();
+ if (expName_0 == null) {
+ throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
@SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
- final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
- CAUGHT_eq_5 = eq_5;
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
+ Variable _lookupUnqualifiedVariable = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
+ CAUGHT_ne = ne;
}
catch (Exception e) {
- CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ CAUGHT_ne = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_ne);
CAUGHT_and_1 = and_1;
}
catch (Exception e) {
CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @NonNull Object CAUGHT_ne;
- try {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
- if (self_1 == null) {
- throw throwNull(lNameExpCS_0, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_0.getExpName();
- if (expName_0 == null) {
- throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
- if (aPathElementCS == null) {
- throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
- Variable _lookupUnqualifiedVariable = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
- CAUGHT_ne = ne;
- }
- catch (Exception e) {
- CAUGHT_ne = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(and_2);
- if (not_1 == null) {
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_1);
+ if (not_0 == null) {
throw throwNull(lNameExpCS_0, "Null if condition");
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_13;
- if (not_1) {
- /*@Caught*/ @NonNull Object CAUGHT_eq_6;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_11;
+ if (not_0) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_2;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS_0.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_6 = roundedBrackets_1 == null;
- CAUGHT_eq_6 = eq_6;
- }
- catch (Exception e) {
- CAUGHT_eq_6 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_5;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_1 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_6 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_1 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_4;
- if (oclIsKindOf_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_2 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6));
- symbol_4 = oclAsType_2;
- }
- else {
- symbol_4 = null;
+ /*@Caught*/ @NonNull Object CAUGHT_eq_3;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_0.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_3 = roundedBrackets_0 == null;
+ CAUGHT_eq_3 = eq_3;
}
- final /*@Thrown*/ boolean eq_7 = symbol_4 == null;
- /*@Thrown*/ boolean symbol_5;
- if (eq_7) {
- symbol_5 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_eq_3 = ValueUtil.createInvalidValue(e);
}
- else {
- if (symbol_4 == null) {
- throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_4;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_3;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_1 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_3 = oclAsType_1;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_1 = symbol_4.getNameExp();
- final /*@Thrown*/ boolean eq_8 = lNameExpCS_0.equals(nameExp_1);
- symbol_5 = eq_8;
+ else {
+ symbol_3 = null;
+ }
+ final /*@Thrown*/ boolean eq_4 = symbol_3 == null;
+ /*@Thrown*/ boolean symbol_4;
+ if (eq_4) {
+ symbol_4 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_3 == null) {
+ throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_3.getNavExp();
+ final /*@Thrown*/ boolean eq_5 = lNameExpCS_0.equals(navExp_0);
+ symbol_4 = eq_5;
+ }
+ CAUGHT_symbol_4 = symbol_4;
}
- CAUGHT_symbol_5 = symbol_5;
+ catch (Exception e) {
+ CAUGHT_symbol_4 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_3, CAUGHT_symbol_4);
+ CAUGHT_and_2 = and_2;
}
catch (Exception e) {
- CAUGHT_symbol_5 = ValueUtil.createInvalidValue(e);
+ CAUGHT_and_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_symbol_5);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(and_3);
- if (not_2 == null) {
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_2);
+ if (not_1 == null) {
throw throwNull(lNameExpCS_0, "Null if condition");
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_12;
- if (not_2) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_0.getAst();
- final /*@Thrown*/ boolean symbol_6 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPropertyCallExp;
- if (symbol_6) {
- final /*@NonInvalid*/ boolean symbol_7 = ast instanceof PropertyCallExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_11;
- if (symbol_7) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp symbol_8 = (PropertyCallExp)ast;
- if (symbol_8 == null) {
- throw throwNull(lNameExpCS_0, "Null where non-null value required");
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_10;
+ if (not_1) {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_6;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS_0.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_6 = roundedBrackets_1 == null;
+ CAUGHT_eq_6 = eq_6;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_6 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not_2;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_6;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_1 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_0);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_6 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_1 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_5;
+ if (oclIsKindOf_1) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_2 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6));
+ symbol_5 = oclAsType_2;
}
- final /*@Thrown*/ boolean symbol_9 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_9) {
- if (ast == null) {
- throw throwNull(lNameExpCS_0, "Null where non-null value required");
- }
- objectManager.getting(symbol_8, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, false);
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property referredProperty = symbol_8.getReferredProperty();
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = referredProperty.getType();
- // property assignments
- symbol_8.setType(type);
- objectManager.assigned(symbol_8, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, type, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_1 = ValueUtil.TRUE_VALUE;
- raw_ast = m_NameExpCS_ast_1;
+ else {
+ symbol_5 = null;
+ }
+ final /*@Thrown*/ boolean eq_7 = symbol_5 == null;
+ /*@Thrown*/ boolean symbol_6;
+ if (eq_7) {
+ symbol_6 = ValueUtil.FALSE_VALUE;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (symbol_5 == null) {
+ throw throwNull(lNameExpCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_1 = symbol_5.getNavExp();
+ final /*@Thrown*/ boolean eq_8 = lNameExpCS_0.equals(navExp_1);
+ symbol_6 = eq_8;
}
- symbol_11 = raw_ast;
+ CAUGHT_symbol_6 = symbol_6;
}
- else {
- symbol_11 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_symbol_6 = ValueUtil.createInvalidValue(e);
}
- raw_aPropertyCallExp = symbol_11;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_6);
+ CAUGHT_not_2 = not_2;
+ }
+ catch (Exception e) {
+ CAUGHT_not_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_not_2);
+ if (and_3 == null) {
+ throw throwNull(lNameExpCS_0, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_9;
+ if (and_3) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_PropertyCallExp_0 = idResolver.getClass(CLSSid_PropertyCallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull PropertyCallExp oclAsType_3 = ClassUtil.nonNullState((PropertyCallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_PropertyCallExp_0));
+ objectManager.getting(oclAsType_3, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, false);
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property referredProperty = oclAsType_3.getReferredProperty();
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = referredProperty.getType();
+ // mapping statements
+ oclAsType_3.setType(type);
+ objectManager.assigned(oclAsType_3, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, type, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_1 = ValueUtil.TRUE_VALUE;
+ symbol_9 = m_NameExpCS_ast_1;
}
else {
- raw_aPropertyCallExp = ValueUtil.FALSE_VALUE;
+ symbol_9 = ValueUtil.FALSE_VALUE;
}
- symbol_12 = raw_aPropertyCallExp;
+ symbol_10 = symbol_9;
}
else {
- symbol_12 = ValueUtil.FALSE_VALUE;
+ symbol_10 = ValueUtil.FALSE_VALUE;
}
- symbol_13 = symbol_12;
+ symbol_11 = symbol_10;
}
else {
- symbol_13 = ValueUtil.FALSE_VALUE;
+ symbol_11 = ValueUtil.FALSE_VALUE;
}
- symbol_14 = symbol_13;
+ raw_ast = symbol_11;
}
else {
- symbol_14 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return symbol_14;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_NameExpCS_ast_1", e);
}
}
+ @Override
public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
return idResolver.oclEquals(lNameExpCS_0, thoseValues[0]);
}
@@ -1524,197 +1542,170 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
* map m_NameExpCS_ast_2 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * {_'if' : minioclcs::CallExpCS[?];
- * parentAsCallExpCS : minioclcs::CallExpCS[?];
- * |}
- * rightAS ( |)
- * {aPropertyCallExp : miniocl::PropertyCallExp[1];
- * ast : miniocl::Element[1];
- * if1 : miniocl::Element[?];
- * ownedSource : miniocl::OCLExpression[1];
- * |}
- * where ( |
- * lNameExpCS.isPropCallExpWithExplicitSource()
- * )
- * {_'=' : Boolean[1];
- * _'=1' : Boolean[1];
- * _'=2' : Boolean[1];
- * |
- * aPropertyCallExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * parentAsCallExpCS := lNameExpCS.parentAsCallExpCS();
- * _'=' := parentAsCallExpCS =
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * var parentAsCallExpCS : minioclcs::CallExpCS[?] := lNameExpCS.parentAsCallExpCS()
+ * ;
+ * check lNameExpCS.isPropCallExpWithExplicitSource();
+ * var _'=' : Boolean[1] := parentAsCallExpCS =
* null;
- * _'if' := if _'='
+ * var aPropertyCallExp : miniocl::PropertyCallExp[1] := ast.oclAsType(miniocl::PropertyCallExp)
+ * ;
+ * var source : minioclcs::CallExpCS[?] := parentAsCallExpCS.source;
+ * var _'if' : minioclcs::CallExpCS[?] := if _'='
* then null
* else parentAsCallExpCS.source
* endif;
- * _'=1' := _'if' =
- * null;
- * if1 := if _'=1'
+ * check source = parentAsCallExpCS.source;
+ * var _'=1' : Boolean[1] := _'if' = null;
+ * var ast1 : miniocl::Element[1] := _'if'.ast;
+ * check ast1 =
+ * _'if'.ast;
+ * var if1 : miniocl::Element[?] := if _'=1'
* then null
- * else _'if'.ast
+ * else ast1
* endif;
- * _'=2' := if1 =
+ * var _'=2' : Boolean[1] := if1 =
* null;
- * ownedSource := if _'=2'
+ * var if2 : miniocl::CallExp[?] := if _'=2'
* then null
- * else if1.oclAsType(miniocl::OCLExpression)
+ * else if1.oclAsType(miniocl::CallExp)
* endif;
- * aPropertyCallExp.ownedSource := ownedSource;
- * }
+ * set aPropertyCallExp.ownedSource := if2;
*
*/
protected boolean MAP_m_NameExpCS_ast_2(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_1) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_1.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
- try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_1.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS_1, "Null where non-null value required");
+ }
final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_1);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
if (oclIsKindOf) {
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
+ symbol_1 = oclAsType;
}
else {
- symbol_0 = null;
+ symbol_1 = null;
}
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_1.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_1, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ catch (Exception e) {
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_3;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_1);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_2 = oclAsType_0;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_1.equals(nameExp);
- symbol_1 = eq_1;
+ else {
+ symbol_2 = null;
+ }
+ final /*@Thrown*/ boolean eq_0 = symbol_2 == null;
+ /*@Thrown*/ boolean symbol_3;
+ if (eq_0) {
+ symbol_3 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_2 == null) {
+ throw throwNull(lNameExpCS_1, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_2.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_1.equals(navExp);
+ symbol_3 = eq_1;
+ }
+ CAUGHT_symbol_3 = symbol_3;
}
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- if (and == null) {
- throw throwNull(lNameExpCS_1, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_16;
- if (and) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_1.getAst();
- final /*@Thrown*/ boolean symbol_2 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPropertyCallExp;
- if (symbol_2) {
- final /*@NonInvalid*/ boolean symbol_3 = ast instanceof PropertyCallExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_15;
- if (symbol_3) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp symbol_4 = (PropertyCallExp)ast;
- if (symbol_4 == null) {
+ catch (Exception e) {
+ CAUGHT_symbol_3 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_3);
+ if (and == null) {
+ throw throwNull(lNameExpCS_1, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_13;
+ if (and) {
+ final /*@Thrown*/ boolean symbol_4 = symbol_1 == null;
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_PropertyCallExp_0 = idResolver.getClass(CLSSid_PropertyCallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull PropertyCallExp oclAsType_1 = ClassUtil.nonNullState((PropertyCallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_PropertyCallExp_0));
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_1, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::source\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS source = symbol_1.getSource();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_5;
+ if (symbol_4) {
+ symbol_5 = null;
+ }
+ else {
+ symbol_5 = source;
+ }
+ final /*@Thrown*/ boolean symbol_6 = symbol_5 == null;
+ if (symbol_5 == null) {
+ throw throwNull(lNameExpCS_1, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CSTrace::ast\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = symbol_5.getAst();
+ final /*@Thrown*/ boolean symbol_7 = ast_0 != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast1;
+ if (symbol_7) {
+ if (ast_0 == null) {
throw throwNull(lNameExpCS_1, "Null where non-null value required");
}
- final /*@Thrown*/ boolean symbol_5 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_5) {
- if (ast == null) {
- throw throwNull(lNameExpCS_1, "Null where non-null value required");
- }
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_1);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_6;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_6 = oclAsType_0;
- }
- else {
- symbol_6 = null;
- }
- final /*@Thrown*/ boolean symbol_7 = symbol_6 == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_8;
- if (symbol_7) {
- symbol_8 = null;
- }
- else {
- if (symbol_6 == null) {
- throw throwNull(lNameExpCS_1, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::source\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS source = symbol_6.getSource();
- symbol_8 = source;
- }
- final /*@Thrown*/ boolean symbol_9 = symbol_8 == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element symbol_10;
- if (symbol_9) {
- symbol_10 = null;
- }
- else {
- if (symbol_8 == null) {
- throw throwNull(lNameExpCS_1, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CSTrace::ast\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_1 = symbol_8.getAst();
- symbol_10 = ast_1;
- }
- final /*@Thrown*/ boolean symbol_11 = symbol_10 == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable OCLExpression symbol_12;
- if (symbol_11) {
- symbol_12 = null;
- }
- else {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_OCLExpression_0 = idResolver.getClass(CLSSid_OCLExpression, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression oclAsType_1 = ClassUtil.nonNullState((OCLExpression)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, symbol_10, TYP_miniocl_c_c_OCLExpression_0));
- symbol_12 = oclAsType_1;
- }
- final /*@Thrown*/ boolean symbol_13 = symbol_12 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ownedSource;
- if (symbol_13) {
- if (symbol_12 == null) {
- throw throwNull(lNameExpCS_1, "Null where non-null value required");
- }
- // property assignments
- symbol_4.setOwnedSource(symbol_12);
- objectManager.assigned(symbol_4, MiniOCLPackage.Literals.CALL_EXP__OWNED_SOURCE, symbol_12, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_2 = ValueUtil.TRUE_VALUE;
- raw_ownedSource = m_NameExpCS_ast_2;
- }
- else {
- raw_ownedSource = ValueUtil.FALSE_VALUE;
- }
- raw_ast = raw_ownedSource;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element symbol_8;
+ if (symbol_6) {
+ symbol_8 = null;
+ }
+ else {
+ symbol_8 = ast_0;
+ }
+ final /*@Thrown*/ boolean symbol_9 = symbol_8 == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable CallExp symbol_10;
+ if (symbol_9) {
+ symbol_10 = null;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_CallExp_0 = idResolver.getClass(CLSSid_CallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull CallExp oclAsType_2 = ClassUtil.nonNullState((CallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, symbol_8, TYP_miniocl_c_c_CallExp_0));
+ symbol_10 = oclAsType_2;
+ }
+ // mapping statements
+ if (symbol_10 == null) {
+ throw throwNull(lNameExpCS_1, "Null value for miniocl::CallExp::ownedSource assignment");
}
- symbol_15 = raw_ast;
+ oclAsType_1.setOwnedSource(symbol_10);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_2 = ValueUtil.TRUE_VALUE;
+ raw_ast1 = m_NameExpCS_ast_2;
}
else {
- symbol_15 = ValueUtil.FALSE_VALUE;
+ raw_ast1 = ValueUtil.FALSE_VALUE;
}
- raw_aPropertyCallExp = symbol_15;
+ symbol_13 = raw_ast1;
}
else {
- raw_aPropertyCallExp = ValueUtil.FALSE_VALUE;
+ symbol_13 = ValueUtil.FALSE_VALUE;
}
- symbol_16 = raw_aPropertyCallExp;
+ raw_ast = symbol_13;
}
else {
- symbol_16 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return symbol_16;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_NameExpCS_ast_2", e);
}
@@ -1723,30 +1714,21 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
* map m_NameExpCS_ast_3 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {aPropertyCallExp : miniocl::PropertyCallExp[1];
- * ast : miniocl::Element[1];
- * referredProperty : miniocl::Property[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |
- * lNameExpCS.isPropCallExpWithExplicitSource())
- * {_'=' : Boolean[1];
- * |
- * aPropertyCallExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * referredProperty := aPropertyCallExp.referredProperty;
- * _'=' := referredProperty =
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * check lNameExpCS.isPropCallExpWithExplicitSource()
+ * ;
+ * var aPropertyCallExp : miniocl::PropertyCallExp[1] := ast.oclAsType(miniocl::PropertyCallExp);
+ * var referredProperty : miniocl::Property[1] := aPropertyCallExp.referredProperty;
+ * var _'=' : Boolean[1] := referredProperty =
* null;
- * type := if _'='
+ * var type : miniocl::Class[1] := referredProperty.type;
+ * var _'if' : miniocl::Class[?] := if _'='
* then null
- * else referredProperty.type
+ * else type
* endif;
- * aPropertyCallExp.type := type;
- * }
+ * notify set aPropertyCallExp.type := _'if';
*
*/
protected class MAP_m_NameExpCS_ast_3 extends AbstractInvocation
@@ -1757,108 +1739,91 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
lNameExpCS_2 = (NameExpCS)boundValues[0];
}
+ @Override
public boolean execute() {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_2.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_2);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_2.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS_2, "Null where non-null value required");
}
- else {
- symbol_0 = null;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_2.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
}
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_2, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_2);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_1 = oclAsType;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_2.equals(nameExp);
- symbol_1 = eq_1;
- }
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- if (and == null) {
- throw throwNull(lNameExpCS_2, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
- if (and) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_2.getAst();
- final /*@Thrown*/ boolean symbol_2 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPropertyCallExp;
- if (symbol_2) {
- final /*@NonInvalid*/ boolean symbol_3 = ast instanceof PropertyCallExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
- if (symbol_3) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp symbol_4 = (PropertyCallExp)ast;
- if (symbol_4 == null) {
- throw throwNull(lNameExpCS_2, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_5 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_5) {
- if (ast == null) {
- throw throwNull(lNameExpCS_2, "Null where non-null value required");
- }
- objectManager.getting(symbol_4, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, false);
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property referredProperty = symbol_4.getReferredProperty();
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = referredProperty.getType();
- // property assignments
- symbol_4.setType(type);
- objectManager.assigned(symbol_4, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, type, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_3 = ValueUtil.TRUE_VALUE;
- raw_ast = m_NameExpCS_ast_3;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
- }
- symbol_7 = raw_ast;
+ else {
+ symbol_1 = null;
+ }
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
+ if (eq_0) {
+ symbol_2 = ValueUtil.FALSE_VALUE;
}
else {
- symbol_7 = ValueUtil.FALSE_VALUE;
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_2, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_2.equals(navExp);
+ symbol_2 = eq_1;
}
- raw_aPropertyCallExp = symbol_7;
+ CAUGHT_symbol_2 = symbol_2;
+ }
+ catch (Exception e) {
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_2);
+ if (and == null) {
+ throw throwNull(lNameExpCS_2, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_5;
+ if (and) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_PropertyCallExp_0 = idResolver.getClass(CLSSid_PropertyCallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull PropertyCallExp oclAsType_0 = ClassUtil.nonNullState((PropertyCallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_PropertyCallExp_0));
+ objectManager.getting(oclAsType_0, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, false);
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property referredProperty = oclAsType_0.getReferredProperty();
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = referredProperty.getType();
+ // mapping statements
+ oclAsType_0.setType(type);
+ objectManager.assigned(oclAsType_0, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, type, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_3 = ValueUtil.TRUE_VALUE;
+ symbol_5 = m_NameExpCS_ast_3;
}
else {
- raw_aPropertyCallExp = ValueUtil.FALSE_VALUE;
+ symbol_5 = ValueUtil.FALSE_VALUE;
}
- symbol_8 = raw_aPropertyCallExp;
+ raw_ast = symbol_5;
}
else {
- symbol_8 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return symbol_8;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_NameExpCS_ast_3", e);
}
}
+ @Override
public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
return idResolver.oclEquals(lNameExpCS_2, thoseValues[0]);
}
@@ -1867,168 +1832,126 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
* map m_NameExpCS_ast_4 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {aVariableExp : miniocl::VariableExp[1];
- * ast : miniocl::Element[1];
- * referredVariable : miniocl::Variable[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |
- * not lNameExpCS.isPropCallExpWithExplicitSource()
- * lNameExpCS.isVariableExp())
- * { |
- * aVariableExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * referredVariable := aVariableExp.referredVariable;
- * type := referredVariable.type;
- * aVariableExp.type := type;
- * }
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * check lNameExpCS.isVariableExp()
+ * ;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource()
+ * ;
+ * var aVariableExp : miniocl::VariableExp[1] := ast.oclAsType(miniocl::VariableExp);
+ * var referredVariable : miniocl::Variable[1] := aVariableExp.referredVariable;
+ * var type : miniocl::Class[1] := referredVariable.type;
+ * notify set aVariableExp.type := type;
*
*/
protected boolean MAP_m_NameExpCS_ast_4(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_3) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_3.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_3);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_3.equals(nameExp);
- symbol_1 = eq_1;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_3.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS_3, "Null where non-null value required");
}
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(and);
- if (not == null) {
- throw throwNull(lNameExpCS_3, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_11;
- if (not) {
- /*@Caught*/ @Nullable Object CAUGHT_and_1;
+ /*@Caught*/ @Nullable Object CAUGHT_and_0;
try {
- /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ /*@Caught*/ @Nullable Object CAUGHT_and;
try {
- /*@Caught*/ @NonNull Object CAUGHT_eq_2;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_3.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
- CAUGHT_eq_2 = eq_2;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_3.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
catch (Exception e) {
- CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @Nullable Object CAUGHT_not_0;
+ /*@Caught*/ @Nullable Object CAUGHT_not;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_3);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_2 = oclAsType_0;
- }
- else {
- symbol_2 = null;
- }
- final /*@Thrown*/ boolean eq_3 = symbol_2 == null;
- /*@Thrown*/ boolean symbol_3;
- if (eq_3) {
- symbol_3 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_2 == null) {
- throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_3);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_1 = oclAsType;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_4 = lNameExpCS_3.equals(nameExp_0);
- symbol_3 = eq_4;
+ else {
+ symbol_1 = null;
+ }
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
+ if (eq_0) {
+ symbol_2 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_3.equals(navExp);
+ symbol_2 = eq_1;
+ }
+ CAUGHT_symbol_2 = symbol_2;
+ }
+ catch (Exception e) {
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(symbol_3);
- CAUGHT_not_0 = not_0;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_2);
+ CAUGHT_not = not;
}
catch (Exception e) {
- CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
+ CAUGHT_not = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
- CAUGHT_and_0 = and_0;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_not);
+ CAUGHT_and = and;
}
catch (Exception e) {
- CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
+ CAUGHT_and = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @NonNull Object CAUGHT_eq_5;
+ /*@Caught*/ @NonNull Object CAUGHT_eq_2;
try {
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_3.getExpName();
if (expName == null) {
- throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
@SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
- final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
- CAUGHT_eq_5 = eq_5;
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
+ final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
+ CAUGHT_eq_2 = eq_2;
}
catch (Exception e) {
- CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
- CAUGHT_and_1 = and_1;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and, CAUGHT_eq_2);
+ CAUGHT_and_0 = and_0;
}
catch (Exception e) {
- CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
+ CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
}
/*@Caught*/ @NonNull Object CAUGHT_ne;
try {
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_3);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_0 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_0.getAst();
if (self_1 == null) {
throw throwNull(lNameExpCS_3, "Null where non-null value required");
}
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_3.getExpName();
if (expName_0 == null) {
- throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
@SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
if (aPathElementCS == null) {
throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
@@ -2046,63 +1969,92 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
catch (Exception e) {
CAUGHT_ne = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
- if (and_2 == null) {
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_ne);
+ if (and_1 == null) {
throw throwNull(lNameExpCS_3, "Null if condition");
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_10;
- if (and_2) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_3.getAst();
- final /*@Thrown*/ boolean symbol_4 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aVariableExp;
- if (symbol_4) {
- final /*@NonInvalid*/ boolean symbol_5 = ast instanceof VariableExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_9;
- if (symbol_5) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable VariableExp symbol_6 = (VariableExp)ast;
- if (symbol_6 == null) {
- throw throwNull(lNameExpCS_3, "Null where non-null value required");
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
+ if (and_1) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_2;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_3;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_3.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_3 = roundedBrackets_0 == null;
+ CAUGHT_eq_3 = eq_3;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_3 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_4;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_3);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_3;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_1 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_3 = oclAsType_1;
}
- final /*@Thrown*/ boolean symbol_7 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_7) {
- if (ast == null) {
- throw throwNull(lNameExpCS_3, "Null where non-null value required");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Variable referredVariable = symbol_6.getReferredVariable();
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = referredVariable.getType();
- // property assignments
- symbol_6.setType(type);
- objectManager.assigned(symbol_6, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, type, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_4 = ValueUtil.TRUE_VALUE;
- raw_ast = m_NameExpCS_ast_4;
+ else {
+ symbol_3 = null;
+ }
+ final /*@Thrown*/ boolean eq_4 = symbol_3 == null;
+ /*@Thrown*/ boolean symbol_4;
+ if (eq_4) {
+ symbol_4 = ValueUtil.FALSE_VALUE;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (symbol_3 == null) {
+ throw throwNull(lNameExpCS_3, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_3.getNavExp();
+ final /*@Thrown*/ boolean eq_5 = lNameExpCS_3.equals(navExp_0);
+ symbol_4 = eq_5;
}
- symbol_9 = raw_ast;
+ CAUGHT_symbol_4 = symbol_4;
}
- else {
- symbol_9 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_symbol_4 = ValueUtil.createInvalidValue(e);
}
- raw_aVariableExp = symbol_9;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_3, CAUGHT_symbol_4);
+ CAUGHT_and_2 = and_2;
+ }
+ catch (Exception e) {
+ CAUGHT_and_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_2);
+ if (not_0 == null) {
+ throw throwNull(lNameExpCS_3, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
+ if (not_0) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_VariableExp_0 = idResolver.getClass(CLSSid_VariableExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull VariableExp oclAsType_2 = ClassUtil.nonNullState((VariableExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_VariableExp_0));
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Variable referredVariable = oclAsType_2.getReferredVariable();
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = referredVariable.getType();
+ // mapping statements
+ oclAsType_2.setType(type);
+ objectManager.assigned(oclAsType_2, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, type, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_4 = ValueUtil.TRUE_VALUE;
+ symbol_7 = m_NameExpCS_ast_4;
}
else {
- raw_aVariableExp = ValueUtil.FALSE_VALUE;
+ symbol_7 = ValueUtil.FALSE_VALUE;
}
- symbol_10 = raw_aVariableExp;
+ symbol_8 = symbol_7;
}
else {
- symbol_10 = ValueUtil.FALSE_VALUE;
+ symbol_8 = ValueUtil.FALSE_VALUE;
}
- symbol_11 = symbol_10;
+ raw_ast = symbol_8;
}
else {
- symbol_11 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return symbol_11;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_NameExpCS_ast_4", e);
}
@@ -2111,31 +2063,22 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
* map m_NameExpCS_ast_expName in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * {expName : minioclcs::PathNameCS[?];
- * |}
- * rightAS ( |)
- * {aPropertyCallExp : miniocl::PropertyCallExp[1];
- * ast : miniocl::Element[1];
- * ownedSource : miniocl::OCLExpression[1];
- * referredProperty : miniocl::Property[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |
- * not lNameExpCS.isPropCallExpWithExplicitSource()
- * not lNameExpCS.isVariableExp()
- * lNameExpCS.isPropCallExpWithImplicitSource()
- * )
- * { |
- * aPropertyCallExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * expName := lNameExpCS.expName;
- * ownedSource := aPropertyCallExp.ownedSource;
- * type := ownedSource.type;
- * referredProperty := aPropertyCallExp.lookupPropertyFrom(type, expName);
- * aPropertyCallExp.referredProperty := referredProperty;
- * }
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * var expName : minioclcs::PathNameCS[?] := lNameExpCS.expName;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource()
+ * ;
+ * check not lNameExpCS.isVariableExp()
+ * ;
+ * check lNameExpCS.isPropCallExpWithImplicitSource()
+ * ;
+ * var aPropertyCallExp : miniocl::PropertyCallExp[1] := ast.oclAsType(miniocl::PropertyCallExp)
+ * ;
+ * var ownedSource : miniocl::OCLExpression[1] := aPropertyCallExp.ownedSource;
+ * var type : miniocl::Class[1] := ownedSource.type;
+ * var lookupPropertyFrom : miniocl::Property[?] := aPropertyCallExp.lookupPropertyFrom(type, expName);
+ * notify set aPropertyCallExp.referredProperty := lookupPropertyFrom;
*
*/
protected class MAP_m_NameExpCS_ast_expName extends AbstractInvocation
@@ -2146,572 +2089,312 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
lNameExpCS_4 = (NameExpCS)boundValues[0];
}
+ @Override
public boolean execute() {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_4.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_4.equals(nameExp);
- symbol_1 = eq_1;
- }
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(and);
- if (not == null) {
- throw throwNull(lNameExpCS_4, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_19;
- if (not) {
- /*@Caught*/ @Nullable Object CAUGHT_and_1;
- try {
- /*@Caught*/ @Nullable Object CAUGHT_and_0;
- try {
- /*@Caught*/ @NonNull Object CAUGHT_eq_2;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_4.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
- CAUGHT_eq_2 = eq_2;
- }
- catch (Exception e) {
- CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @Nullable Object CAUGHT_not_0;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_2 = oclAsType_0;
- }
- else {
- symbol_2 = null;
- }
- final /*@Thrown*/ boolean eq_3 = symbol_2 == null;
- /*@Thrown*/ boolean symbol_3;
- if (eq_3) {
- symbol_3 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_2 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_4 = lNameExpCS_4.equals(nameExp_0);
- symbol_3 = eq_4;
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(symbol_3);
- CAUGHT_not_0 = not_0;
- }
- catch (Exception e) {
- CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
- CAUGHT_and_0 = and_0;
- }
- catch (Exception e) {
- CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_eq_5;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_4.getExpName();
- if (expName == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
- final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
- CAUGHT_eq_5 = eq_5;
- }
- catch (Exception e) {
- CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
- CAUGHT_and_1 = and_1;
- }
- catch (Exception e) {
- CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_4.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS_4, "Null where non-null value required");
}
- /*@Caught*/ @NonNull Object CAUGHT_ne;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_4.getExpName();
+ /*@Caught*/ @Nullable Object CAUGHT_and;
try {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
- if (self_1 == null) {
- throw throwNull(lNameExpCS_4, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_4.getExpName();
- if (expName_0 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
- if (aPathElementCS == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
- Variable _lookupUnqualifiedVariable = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
- CAUGHT_ne = ne;
- }
- catch (Exception e) {
- CAUGHT_ne = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(and_2);
- if (not_1 == null) {
- throw throwNull(lNameExpCS_4, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_18;
- if (not_1) {
- /*@Caught*/ @NonNull Object CAUGHT_eq_6;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS_4.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_6 = roundedBrackets_1 == null;
- CAUGHT_eq_6 = eq_6;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_4.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
catch (Exception e) {
- CAUGHT_eq_6 = ValueUtil.createInvalidValue(e);
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @Nullable Object CAUGHT_not_2;
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_1 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_6 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_1 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_4;
- if (oclIsKindOf_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_2 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6));
- symbol_4 = oclAsType_2;
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_1 = oclAsType;
}
else {
- symbol_4 = null;
+ symbol_1 = null;
}
- final /*@Thrown*/ boolean eq_7 = symbol_4 == null;
- /*@Thrown*/ boolean symbol_5;
- if (eq_7) {
- symbol_5 = ValueUtil.FALSE_VALUE;
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
+ if (eq_0) {
+ symbol_2 = ValueUtil.FALSE_VALUE;
}
else {
- if (symbol_4 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_1 = symbol_4.getNameExp();
- final /*@Thrown*/ boolean eq_8 = lNameExpCS_4.equals(nameExp_1);
- symbol_5 = eq_8;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_4.equals(navExp);
+ symbol_2 = eq_1;
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(symbol_5);
- CAUGHT_not_2 = not_2;
+ CAUGHT_symbol_2 = symbol_2;
}
catch (Exception e) {
- CAUGHT_not_2 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_not_2);
- if (and_3 == null) {
- throw throwNull(lNameExpCS_4, "Null if condition");
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_17;
- if (and_3) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_4.getAst();
- final /*@Thrown*/ boolean symbol_6 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPropertyCallExp;
- if (symbol_6) {
- final /*@NonInvalid*/ boolean symbol_7 = ast instanceof PropertyCallExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_16;
- if (symbol_7) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp symbol_8 = (PropertyCallExp)ast;
- if (symbol_8 == null) {
- throw throwNull(lNameExpCS_4, "Null where non-null value required");
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_2);
+ CAUGHT_and = and;
+ }
+ catch (Exception e) {
+ CAUGHT_and = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and);
+ if (not == null) {
+ throw throwNull(lNameExpCS_4, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_15;
+ if (not) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_2;
+ try {
+ /*@Caught*/ @Nullable Object CAUGHT_and_1;
+ try {
+ /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_2;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_4.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
+ CAUGHT_eq_2 = eq_2;
}
- final /*@Thrown*/ boolean symbol_9 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_9) {
- if (ast == null) {
- throw throwNull(lNameExpCS_4, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_1 = lNameExpCS_4.getExpName();
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression ownedSource = symbol_8.getOwnedSource();
- objectManager.getting(ownedSource, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, false);
- @SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = ownedSource.getType();
- if (expName_1 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = expName_1.getPathElements();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size_0 = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
- final /*@Thrown*/ boolean eq_9 = size_0.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property symbol_13;
- if (eq_9) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_0 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult_0 = lookupSolver._lookupExportedProperty(type, symbol_8, (String)elementName_0);
- org.eclipse.qvtd.doc.miniocl.Property _lookupExportedProperty = null;
- if (_lookupResult_0.size() == 1) {
- _lookupExportedProperty = _lookupResult_0.getSingleResult();
- } else {
- handleLookupError(symbol_8,symbol_8);
- };
- symbol_13 = _lookupExportedProperty;
- }
- else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size_0, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size_2 = CollectionSizeOperation.INSTANCE.evaluate(qualifierSegments);
- final /*@Thrown*/ boolean eq_10 = size_2.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_11;
- if (eq_10) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_1 = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(qualifierSegments);
- if (aPathElementCS_1 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_1 = aPathElementCS_1.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_1 = lookupSolver._lookupUnqualifiedClass(symbol_8, (String)elementName_1);
- org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
- if (_lookupResult_1.size() == 1) {
- _lookupUnqualifiedClass = _lookupResult_1.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_1,elementName_1);
- };
- symbol_11 = _lookupUnqualifiedClass;
+ catch (Exception e) {
+ CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not_0;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_4;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_3;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_3 = oclAsType_0;
}
else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff_0 = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size_2, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments_0 = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(qualifierSegments, INT_1, diff_0);
- final List<PathElementCS> UNBOXED_qualifierSegments_0 = qualifierSegments_0.asEcoreObjects(idResolver, PathElementCS.class);
- assert UNBOXED_qualifierSegments_0 != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = MiniOCLCS2AS_qvtp_qvtcas.this.lookupPackage(symbol_8, UNBOXED_qualifierSegments_0);
- /*@Caught*/ @Nullable Object CAUGHT_qualifier;
- try {
- CAUGHT_qualifier = qualifier;
- }
- catch (Exception e) {
- CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
- }
- final /*@NonInvalid*/ @NonNull Object symbol_10 = CAUGHT_qualifier == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
- if (symbol_10 == Boolean.TRUE) {
- safe_lookupQualifiedClass_source = null;
- }
- else {
- if (qualifier == null) {
- throw throwNull(lNameExpCS_4, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_2 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(qualifierSegments);
- if (aPathElementCS_2 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_2 = aPathElementCS_2.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_2 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_2);
- org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
- if (_lookupResult_2.size() == 1) {
- _lookupQualifiedClass = _lookupResult_2.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_2,elementName_2);
- };
- safe_lookupQualifiedClass_source = _lookupQualifiedClass;
- }
- symbol_11 = safe_lookupQualifiedClass_source;
- }
- /*@Caught*/ @Nullable Object CAUGHT_symbol_11;
- try {
- CAUGHT_symbol_11 = symbol_11;
- }
- catch (Exception e) {
- CAUGHT_symbol_11 = ValueUtil.createInvalidValue(e);
+ symbol_3 = null;
}
- final /*@NonInvalid*/ @NonNull Object symbol_12 = CAUGHT_symbol_11 == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property safe_lookupQualifiedProperty_source;
- if (symbol_12 == Boolean.TRUE) {
- safe_lookupQualifiedProperty_source = null;
+ final /*@Thrown*/ boolean eq_3 = symbol_3 == null;
+ /*@Thrown*/ boolean symbol_4;
+ if (eq_3) {
+ symbol_4 = ValueUtil.FALSE_VALUE;
}
else {
- if (symbol_11 == null) {
- throw throwNull(lNameExpCS_4, "Null where non-null value required");
+ if (symbol_3 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_3 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_3 == null) {
- throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_3 = aPathElementCS_3.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult_3 = lookupSolver._lookupQualifiedProperty(symbol_11, (String)elementName_3);
- org.eclipse.qvtd.doc.miniocl.Property _lookupQualifiedProperty = null;
- if (_lookupResult_3.size() == 1) {
- _lookupQualifiedProperty = _lookupResult_3.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_3,elementName_3);
- };
- safe_lookupQualifiedProperty_source = _lookupQualifiedProperty;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_3.getNavExp();
+ final /*@Thrown*/ boolean eq_4 = lNameExpCS_4.equals(navExp_0);
+ symbol_4 = eq_4;
}
- symbol_13 = safe_lookupQualifiedProperty_source;
+ CAUGHT_symbol_4 = symbol_4;
}
- final /*@Thrown*/ boolean symbol_14 = symbol_13 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_referredProperty;
- if (symbol_14) {
- if (symbol_13 == null) {
- throw throwNull(lNameExpCS_4, "Null where non-null value required");
- }
- // property assignments
- symbol_8.setReferredProperty(symbol_13);
- objectManager.assigned(symbol_8, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, symbol_13, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_expName = ValueUtil.TRUE_VALUE;
- raw_referredProperty = m_NameExpCS_ast_expName;
- }
- else {
- raw_referredProperty = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_symbol_4 = ValueUtil.createInvalidValue(e);
}
- raw_ast = raw_referredProperty;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_4);
+ CAUGHT_not_0 = not_0;
}
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
}
- symbol_16 = raw_ast;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
+ CAUGHT_and_0 = and_0;
}
- else {
- symbol_16 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
}
- raw_aPropertyCallExp = symbol_16;
+ /*@Caught*/ @NonNull Object CAUGHT_eq_5;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_4.getExpName();
+ if (expName_0 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
+ final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
+ CAUGHT_eq_5 = eq_5;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
+ CAUGHT_and_1 = and_1;
}
- else {
- raw_aPropertyCallExp = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
}
- symbol_17 = raw_aPropertyCallExp;
+ /*@Caught*/ @NonNull Object CAUGHT_ne;
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
+ if (self_1 == null) {
+ throw throwNull(lNameExpCS_4, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_1 = lNameExpCS_4.getExpName();
+ if (expName_1 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_1.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
+ Variable _lookupUnqualifiedVariable = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
+ CAUGHT_ne = ne;
+ }
+ catch (Exception e) {
+ CAUGHT_ne = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
+ CAUGHT_and_2 = and_2;
}
- else {
- symbol_17 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_and_2 = ValueUtil.createInvalidValue(e);
}
- symbol_18 = symbol_17;
- }
- else {
- symbol_18 = ValueUtil.FALSE_VALUE;
- }
- symbol_19 = symbol_18;
- }
- else {
- symbol_19 = ValueUtil.FALSE_VALUE;
- }
- return symbol_19;
- } catch (Throwable e) {
- return handleExecutionFailure("MAP_m_NameExpCS_ast_expName", e);
- }
- }
-
- public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
- return idResolver.oclEquals(lNameExpCS_4, thoseValues[0]);
- }
- }
-
- /**
- *
- * map m_NameExpCS_ast_expName_1 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * {expName : minioclcs::PathNameCS[?];
- * |}
- * rightAS ( |)
- * {aPropertyCallExp : miniocl::PropertyCallExp[1];
- * ast : miniocl::Element[1];
- * ownedSource : miniocl::OCLExpression[1];
- * referredProperty : miniocl::Property[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |
- * lNameExpCS.isPropCallExpWithExplicitSource()
- * )
- * { |
- * aPropertyCallExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * expName := lNameExpCS.expName;
- * ownedSource := aPropertyCallExp.ownedSource;
- * type := ownedSource.type;
- * referredProperty := aPropertyCallExp.lookupPropertyFrom(type, expName);
- * aPropertyCallExp.referredProperty := referredProperty;
- * }
- *
- */
- protected class MAP_m_NameExpCS_ast_expName_1 extends AbstractInvocation
- {
- protected final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_5;
-
- public MAP_m_NameExpCS_ast_expName_1(@NonNull Object @NonNull [] boundValues) {
- lNameExpCS_5 = (NameExpCS)boundValues[0];
- }
-
- public boolean execute() {
- try {
- // predicates and unrealized variables
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_5.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_5);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_2);
+ if (not_1 == null) {
+ throw throwNull(lNameExpCS_4, "Null if condition");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_5.equals(nameExp);
- symbol_1 = eq_1;
- }
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- if (and == null) {
- throw throwNull(lNameExpCS_5, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_13;
- if (and) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_5.getAst();
- final /*@Thrown*/ boolean symbol_2 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPropertyCallExp;
- if (symbol_2) {
- final /*@NonInvalid*/ boolean symbol_3 = ast instanceof PropertyCallExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_12;
- if (symbol_3) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp symbol_4 = (PropertyCallExp)ast;
- if (symbol_4 == null) {
- throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_14;
+ if (not_1) {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_6;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS_4.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_6 = roundedBrackets_1 == null;
+ CAUGHT_eq_6 = eq_6;
}
- final /*@Thrown*/ boolean symbol_5 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_5) {
- if (ast == null) {
- throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ catch (Exception e) {
+ CAUGHT_eq_6 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not_2;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_6;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_1 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_4);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_6 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_1 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_5;
+ if (oclIsKindOf_1) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_2 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_1, TYP_minioclcs_c_c_CallExpCS_6));
+ symbol_5 = oclAsType_2;
+ }
+ else {
+ symbol_5 = null;
+ }
+ final /*@Thrown*/ boolean eq_7 = symbol_5 == null;
+ /*@Thrown*/ boolean symbol_6;
+ if (eq_7) {
+ symbol_6 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_5 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_1 = symbol_5.getNavExp();
+ final /*@Thrown*/ boolean eq_8 = lNameExpCS_4.equals(navExp_1);
+ symbol_6 = eq_8;
+ }
+ CAUGHT_symbol_6 = symbol_6;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_5.getExpName();
+ catch (Exception e) {
+ CAUGHT_symbol_6 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_6);
+ CAUGHT_not_2 = not_2;
+ }
+ catch (Exception e) {
+ CAUGHT_not_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_not_2);
+ if (and_3 == null) {
+ throw throwNull(lNameExpCS_4, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_13;
+ if (and_3) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_PropertyCallExp_0 = idResolver.getClass(CLSSid_PropertyCallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull PropertyCallExp oclAsType_3 = ClassUtil.nonNullState((PropertyCallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_PropertyCallExp_0));
@SuppressWarnings("null")
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression ownedSource = symbol_4.getOwnedSource();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression ownedSource = oclAsType_3.getOwnedSource();
objectManager.getting(ownedSource, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, false);
@SuppressWarnings("null")
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = ownedSource.getType();
if (expName == null) {
- throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
@SuppressWarnings("null")
final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = expName.getPathElements();
final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
- final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property symbol_9;
- if (eq_2) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS == null) {
- throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size_0 = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
+ final /*@Thrown*/ boolean eq_9 = size_0.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property symbol_10;
+ if (eq_9) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS_0 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult = lookupSolver._lookupExportedProperty(type, symbol_4, (String)elementName);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult_0 = lookupSolver._lookupExportedProperty(type, oclAsType_3, (String)elementName_0);
org.eclipse.qvtd.doc.miniocl.Property _lookupExportedProperty = null;
- if (_lookupResult.size() == 1) {
- _lookupExportedProperty = _lookupResult.getSingleResult();
+ if (_lookupResult_0.size() == 1) {
+ _lookupExportedProperty = _lookupResult_0.getSingleResult();
} else {
- handleLookupError(symbol_4,symbol_4);
+ handleLookupError(oclAsType_3,oclAsType_3);
};
- symbol_9 = _lookupExportedProperty;
+ symbol_10 = _lookupExportedProperty;
}
else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size_0, INT_1);
final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size_1 = CollectionSizeOperation.INSTANCE.evaluate(qualifierSegments);
- final /*@Thrown*/ boolean eq_3 = size_1.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_7;
- if (eq_3) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(qualifierSegments);
- if (aPathElementCS_0 == null) {
- throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size_2 = CollectionSizeOperation.INSTANCE.evaluate(qualifierSegments);
+ final /*@Thrown*/ boolean eq_10 = size_2.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_8;
+ if (eq_10) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_1 = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(qualifierSegments);
+ if (aPathElementCS_1 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupUnqualifiedClass(symbol_4, (String)elementName_0);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_1 = aPathElementCS_1.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_1 = lookupSolver._lookupUnqualifiedClass(oclAsType_3, (String)elementName_1);
org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
- if (_lookupResult_0.size() == 1) {
- _lookupUnqualifiedClass = _lookupResult_0.getSingleResult();
+ if (_lookupResult_1.size() == 1) {
+ _lookupUnqualifiedClass = _lookupResult_1.getSingleResult();
} else {
- handleLookupError(aPathElementCS_0,elementName_0);
+ handleLookupError(aPathElementCS_1,elementName_1);
};
- symbol_7 = _lookupUnqualifiedClass;
+ symbol_8 = _lookupUnqualifiedClass;
}
else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff_0 = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size_1, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff_0 = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size_2, INT_1);
final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments_0 = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(qualifierSegments, INT_1, diff_0);
final List<PathElementCS> UNBOXED_qualifierSegments_0 = qualifierSegments_0.asEcoreObjects(idResolver, PathElementCS.class);
assert UNBOXED_qualifierSegments_0 != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = MiniOCLCS2AS_qvtp_qvtcas.this.lookupPackage(symbol_4, UNBOXED_qualifierSegments_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = INST_Visitable_lookupPackage.evaluate(oclAsType_3, UNBOXED_qualifierSegments_0);
/*@Caught*/ @Nullable Object CAUGHT_qualifier;
try {
CAUGHT_qualifier = qualifier;
@@ -2719,1168 +2402,1123 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
catch (Exception e) {
CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
}
- final /*@NonInvalid*/ @NonNull Object symbol_6 = CAUGHT_qualifier == null;
+ final /*@NonInvalid*/ @NonNull Object symbol_7 = CAUGHT_qualifier == null;
/*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
- if (symbol_6 == Boolean.TRUE) {
+ if (symbol_7 == Boolean.TRUE) {
safe_lookupQualifiedClass_source = null;
}
else {
if (qualifier == null) {
- throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ throw throwNull(lNameExpCS_4, "Null where non-null value required");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_1 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(qualifierSegments);
- if (aPathElementCS_1 == null) {
- throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_2 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(qualifierSegments);
+ if (aPathElementCS_2 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_1 = aPathElementCS_1.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_1 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_1);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_2 = aPathElementCS_2.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_2 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_2);
org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
- if (_lookupResult_1.size() == 1) {
- _lookupQualifiedClass = _lookupResult_1.getSingleResult();
+ if (_lookupResult_2.size() == 1) {
+ _lookupQualifiedClass = _lookupResult_2.getSingleResult();
} else {
- handleLookupError(aPathElementCS_1,elementName_1);
+ handleLookupError(aPathElementCS_2,elementName_2);
};
safe_lookupQualifiedClass_source = _lookupQualifiedClass;
}
- symbol_7 = safe_lookupQualifiedClass_source;
+ symbol_8 = safe_lookupQualifiedClass_source;
}
- /*@Caught*/ @Nullable Object CAUGHT_symbol_7;
+ /*@Caught*/ @Nullable Object CAUGHT_symbol_8;
try {
- CAUGHT_symbol_7 = symbol_7;
+ CAUGHT_symbol_8 = symbol_8;
}
catch (Exception e) {
- CAUGHT_symbol_7 = ValueUtil.createInvalidValue(e);
+ CAUGHT_symbol_8 = ValueUtil.createInvalidValue(e);
}
- final /*@NonInvalid*/ @NonNull Object symbol_8 = CAUGHT_symbol_7 == null;
+ final /*@NonInvalid*/ @NonNull Object symbol_9 = CAUGHT_symbol_8 == null;
/*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property safe_lookupQualifiedProperty_source;
- if (symbol_8 == Boolean.TRUE) {
+ if (symbol_9 == Boolean.TRUE) {
safe_lookupQualifiedProperty_source = null;
}
else {
- if (symbol_7 == null) {
- throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ if (symbol_8 == null) {
+ throw throwNull(lNameExpCS_4, "Null where non-null value required");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_2 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_2 == null) {
- throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_3 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS_3 == null) {
+ throw throwNull(lNameExpCS_4, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_2 = aPathElementCS_2.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult_2 = lookupSolver._lookupQualifiedProperty(symbol_7, (String)elementName_2);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_3 = aPathElementCS_3.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult_3 = lookupSolver._lookupQualifiedProperty(symbol_8, (String)elementName_3);
org.eclipse.qvtd.doc.miniocl.Property _lookupQualifiedProperty = null;
- if (_lookupResult_2.size() == 1) {
- _lookupQualifiedProperty = _lookupResult_2.getSingleResult();
+ if (_lookupResult_3.size() == 1) {
+ _lookupQualifiedProperty = _lookupResult_3.getSingleResult();
} else {
- handleLookupError(aPathElementCS_2,elementName_2);
+ handleLookupError(aPathElementCS_3,elementName_3);
};
safe_lookupQualifiedProperty_source = _lookupQualifiedProperty;
}
- symbol_9 = safe_lookupQualifiedProperty_source;
- }
- final /*@Thrown*/ boolean symbol_10 = symbol_9 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_referredProperty;
- if (symbol_10) {
- if (symbol_9 == null) {
- throw throwNull(lNameExpCS_5, "Null where non-null value required");
- }
- // property assignments
- symbol_4.setReferredProperty(symbol_9);
- objectManager.assigned(symbol_4, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, symbol_9, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_expName_1 = ValueUtil.TRUE_VALUE;
- raw_referredProperty = m_NameExpCS_ast_expName_1;
+ symbol_10 = safe_lookupQualifiedProperty_source;
}
- else {
- raw_referredProperty = ValueUtil.FALSE_VALUE;
+ // mapping statements
+ if (symbol_10 == null) {
+ throw throwNull(lNameExpCS_4, "Null value for miniocl::PropertyCallExp::referredProperty assignment");
}
- raw_ast = raw_referredProperty;
+ oclAsType_3.setReferredProperty(symbol_10);
+ objectManager.assigned(oclAsType_3, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, symbol_10, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_expName = ValueUtil.TRUE_VALUE;
+ symbol_13 = m_NameExpCS_ast_expName;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ symbol_13 = ValueUtil.FALSE_VALUE;
}
- symbol_12 = raw_ast;
+ symbol_14 = symbol_13;
}
else {
- symbol_12 = ValueUtil.FALSE_VALUE;
+ symbol_14 = ValueUtil.FALSE_VALUE;
}
- raw_aPropertyCallExp = symbol_12;
+ symbol_15 = symbol_14;
}
else {
- raw_aPropertyCallExp = ValueUtil.FALSE_VALUE;
+ symbol_15 = ValueUtil.FALSE_VALUE;
}
- symbol_13 = raw_aPropertyCallExp;
+ raw_ast = symbol_15;
}
else {
- symbol_13 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return symbol_13;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_NameExpCS_ast_expName_1", e);
+ return handleExecutionFailure("MAP_m_NameExpCS_ast_expName", e);
}
}
+ @Override
public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
- return idResolver.oclEquals(lNameExpCS_5, thoseValues[0]);
+ return idResolver.oclEquals(lNameExpCS_4, thoseValues[0]);
}
}
/**
*
- * map m_NameExpCS_ast_expName_2 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * {expName : minioclcs::PathNameCS[?];
- * first : minioclcs::PathElementCS[?];
- * path : OrderedSet(minioclcs::PathElementCS)[*|1];
- * |}
- * rightAS ( |)
- * {aVariableExp : miniocl::VariableExp[1];
- * ast : miniocl::Element[1];
- * referredVariable : miniocl::Variable[1];
- * |}
- * where ( |
- * lNameExpCS.isVariableExp()
- * not lNameExpCS.isPropCallExpWithExplicitSource()
- * )
- * { |
- * aVariableExp := lNameExpCS.ast;
- * ast := lNameExpCS.ast;
- * expName := lNameExpCS.expName;
- * path := expName.path;
- * first := path->first()
+ * map m_NameExpCS_ast_expName_1 in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * var expName : minioclcs::PathNameCS[?] := lNameExpCS.expName;
+ * check lNameExpCS.isPropCallExpWithExplicitSource()
+ * ;
+ * var aPropertyCallExp : miniocl::PropertyCallExp[1] := ast.oclAsType(miniocl::PropertyCallExp)
* ;
- * referredVariable := aVariableExp.lookupVariable(first);
- * aVariableExp.referredVariable := referredVariable;
- * }
+ * var ownedSource : miniocl::OCLExpression[1] := aPropertyCallExp.ownedSource;
+ * var type : miniocl::Class[1] := ownedSource.type;
+ * var lookupPropertyFrom : miniocl::Property[?] := aPropertyCallExp.lookupPropertyFrom(type, expName);
+ * notify set aPropertyCallExp.referredProperty := lookupPropertyFrom;
*
*/
- protected boolean MAP_m_NameExpCS_ast_expName_2(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_6) {
- try {
- // predicates and unrealized variables
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ protected class MAP_m_NameExpCS_ast_expName_1 extends AbstractInvocation
+ {
+ protected final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_5;
+
+ public MAP_m_NameExpCS_ast_expName_1(@NonNull Object @NonNull [] boundValues) {
+ lNameExpCS_5 = (NameExpCS)boundValues[0];
+ }
+
+ @Override
+ public boolean execute() {
try {
- /*@Caught*/ @Nullable Object CAUGHT_and;
- try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_5.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_5.getExpName();
/*@Caught*/ @NonNull Object CAUGHT_eq;
try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_6.getRoundedBrackets();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_5.getRoundedBrackets();
final /*@Thrown*/ boolean eq = roundedBrackets == null;
CAUGHT_eq = eq;
}
catch (Exception e) {
CAUGHT_eq = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @Nullable Object CAUGHT_not;
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_6);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_5);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
if (oclIsKindOf) {
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
+ symbol_1 = oclAsType;
}
else {
- symbol_0 = null;
+ symbol_1 = null;
}
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
+ symbol_2 = ValueUtil.FALSE_VALUE;
}
else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_6.equals(nameExp);
- symbol_1 = eq_1;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_5.equals(navExp);
+ symbol_2 = eq_1;
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(symbol_1);
- CAUGHT_not = not;
+ CAUGHT_symbol_2 = symbol_2;
}
catch (Exception e) {
- CAUGHT_not = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_not);
- CAUGHT_and = and;
- }
- catch (Exception e) {
- CAUGHT_and = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_eq_2;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_6.getExpName();
- if (expName == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
- final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
- CAUGHT_eq_2 = eq_2;
- }
- catch (Exception e) {
- CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and, CAUGHT_eq_2);
- CAUGHT_and_0 = and_0;
- }
- catch (Exception e) {
- CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_ne;
- try {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_6);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_0 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_0.getAst();
- if (self_1 == null) {
- throw throwNull(lNameExpCS_6, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_6.getExpName();
- if (expName_0 == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
- if (aPathElementCS == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
- Variable _lookupUnqualifiedVariable = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
- CAUGHT_ne = ne;
- }
- catch (Exception e) {
- CAUGHT_ne = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_ne);
- if (and_1 == null) {
- throw throwNull(lNameExpCS_6, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_12;
- if (and_1) {
- /*@Caught*/ @NonNull Object CAUGHT_eq_3;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_6.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_3 = roundedBrackets_0 == null;
- CAUGHT_eq_3 = eq_3;
- }
- catch (Exception e) {
- CAUGHT_eq_3 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_3;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_6);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_1 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_2 = oclAsType_1;
- }
- else {
- symbol_2 = null;
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ boolean eq_4 = symbol_2 == null;
- /*@Thrown*/ boolean symbol_3;
- if (eq_4) {
- symbol_3 = ValueUtil.FALSE_VALUE;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_2);
+ if (and == null) {
+ throw throwNull(lNameExpCS_5, "Null if condition");
}
- else {
- if (symbol_2 == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_9;
+ if (and) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_PropertyCallExp_0 = idResolver.getClass(CLSSid_PropertyCallExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull PropertyCallExp oclAsType_0 = ClassUtil.nonNullState((PropertyCallExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_PropertyCallExp_0));
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression ownedSource = oclAsType_0.getOwnedSource();
+ objectManager.getting(ownedSource, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, false);
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = ownedSource.getType();
+ if (expName == null) {
+ throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_5 = lNameExpCS_6.equals(nameExp_0);
- symbol_3 = eq_5;
- }
- CAUGHT_symbol_3 = symbol_3;
- }
- catch (Exception e) {
- CAUGHT_symbol_3 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_3, CAUGHT_symbol_3);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(and_2);
- if (not_0 == null) {
- throw throwNull(lNameExpCS_6, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_11;
- if (not_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_6.getAst();
- final /*@Thrown*/ boolean symbol_4 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aVariableExp;
- if (symbol_4) {
- final /*@NonInvalid*/ boolean symbol_5 = ast instanceof VariableExp;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_10;
- if (symbol_5) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable VariableExp symbol_6 = (VariableExp)ast;
- if (symbol_6 == null) {
- throw throwNull(lNameExpCS_6, "Null where non-null value required");
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
+ final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property symbol_6;
+ if (eq_2) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ boolean symbol_7 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_7) {
- if (ast == null) {
- throw throwNull(lNameExpCS_6, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_1 = lNameExpCS_6.getExpName();
- if (expName_1 == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_1 = expName_1.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_1 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_1);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS first = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_1);
- if (first == null) {
- throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult = lookupSolver._lookupExportedProperty(type, oclAsType_0, (String)elementName);
+ org.eclipse.qvtd.doc.miniocl.Property _lookupExportedProperty = null;
+ if (_lookupResult.size() == 1) {
+ _lookupExportedProperty = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(oclAsType_0,oclAsType_0);
+ };
+ symbol_6 = _lookupExportedProperty;
+ }
+ else {
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size_1 = CollectionSizeOperation.INSTANCE.evaluate(qualifierSegments);
+ final /*@Thrown*/ boolean eq_3 = size_1.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_4;
+ if (eq_3) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(qualifierSegments);
+ if (aPathElementCS_0 == null) {
+ throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = first.getElementName();
- MiniOCLLookupResult<Variable> _lookupResult_0 = lookupSolver._lookupUnqualifiedVariable(symbol_6, (String)elementName_0);
- Variable _lookupUnqualifiedVariable_0 = null;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupUnqualifiedClass(oclAsType_0, (String)elementName_0);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
if (_lookupResult_0.size() == 1) {
- _lookupUnqualifiedVariable_0 = _lookupResult_0.getSingleResult();
+ _lookupUnqualifiedClass = _lookupResult_0.getSingleResult();
} else {
- handleLookupError(first,elementName_0);
+ handleLookupError(aPathElementCS_0,elementName_0);
};
- final /*@Thrown*/ boolean symbol_8 = _lookupUnqualifiedVariable_0 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_referredVariable;
- if (symbol_8) {
- if (_lookupUnqualifiedVariable_0 == null) {
- throw throwNull(lNameExpCS_6, "Null where non-null value required");
- }
- // property assignments
- symbol_6.setReferredVariable(_lookupUnqualifiedVariable_0);
- objectManager.assigned(symbol_6, MiniOCLPackage.Literals.VARIABLE_EXP__REFERRED_VARIABLE, _lookupUnqualifiedVariable_0, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_expName_2 = ValueUtil.TRUE_VALUE;
- raw_referredVariable = m_NameExpCS_ast_expName_2;
+ symbol_4 = _lookupUnqualifiedClass;
+ }
+ else {
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff_0 = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size_1, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments_0 = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(qualifierSegments, INT_1, diff_0);
+ final List<PathElementCS> UNBOXED_qualifierSegments_0 = qualifierSegments_0.asEcoreObjects(idResolver, PathElementCS.class);
+ assert UNBOXED_qualifierSegments_0 != null;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = INST_Visitable_lookupPackage.evaluate(oclAsType_0, UNBOXED_qualifierSegments_0);
+ /*@Caught*/ @Nullable Object CAUGHT_qualifier;
+ try {
+ CAUGHT_qualifier = qualifier;
+ }
+ catch (Exception e) {
+ CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
+ }
+ final /*@NonInvalid*/ @NonNull Object symbol_3 = CAUGHT_qualifier == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
+ if (symbol_3 == Boolean.TRUE) {
+ safe_lookupQualifiedClass_source = null;
}
else {
- raw_referredVariable = ValueUtil.FALSE_VALUE;
+ if (qualifier == null) {
+ throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_1 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(qualifierSegments);
+ if (aPathElementCS_1 == null) {
+ throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_1 = aPathElementCS_1.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_1 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_1);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
+ if (_lookupResult_1.size() == 1) {
+ _lookupQualifiedClass = _lookupResult_1.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS_1,elementName_1);
+ };
+ safe_lookupQualifiedClass_source = _lookupQualifiedClass;
}
- raw_ast = raw_referredVariable;
+ symbol_4 = safe_lookupQualifiedClass_source;
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_symbol_4;
+ try {
+ CAUGHT_symbol_4 = symbol_4;
+ }
+ catch (Exception e) {
+ CAUGHT_symbol_4 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@NonInvalid*/ @NonNull Object symbol_5 = CAUGHT_symbol_4 == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property safe_lookupQualifiedProperty_source;
+ if (symbol_5 == Boolean.TRUE) {
+ safe_lookupQualifiedProperty_source = null;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (symbol_4 == null) {
+ throw throwNull(lNameExpCS_5, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_2 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS_2 == null) {
+ throw throwNull(lNameExpCS_5, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_2 = aPathElementCS_2.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Property> _lookupResult_2 = lookupSolver._lookupQualifiedProperty(symbol_4, (String)elementName_2);
+ org.eclipse.qvtd.doc.miniocl.Property _lookupQualifiedProperty = null;
+ if (_lookupResult_2.size() == 1) {
+ _lookupQualifiedProperty = _lookupResult_2.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS_2,elementName_2);
+ };
+ safe_lookupQualifiedProperty_source = _lookupQualifiedProperty;
}
- symbol_10 = raw_ast;
+ symbol_6 = safe_lookupQualifiedProperty_source;
}
- else {
- symbol_10 = ValueUtil.FALSE_VALUE;
+ // mapping statements
+ if (symbol_6 == null) {
+ throw throwNull(lNameExpCS_5, "Null value for miniocl::PropertyCallExp::referredProperty assignment");
}
- raw_aVariableExp = symbol_10;
+ oclAsType_0.setReferredProperty(symbol_6);
+ objectManager.assigned(oclAsType_0, MiniOCLPackage.Literals.PROPERTY_CALL_EXP__REFERRED_PROPERTY, symbol_6, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_expName_1 = ValueUtil.TRUE_VALUE;
+ symbol_9 = m_NameExpCS_ast_expName_1;
}
else {
- raw_aVariableExp = ValueUtil.FALSE_VALUE;
+ symbol_9 = ValueUtil.FALSE_VALUE;
}
- symbol_11 = raw_aVariableExp;
+ raw_ast = symbol_9;
}
else {
- symbol_11 = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- symbol_12 = symbol_11;
- }
- else {
- symbol_12 = ValueUtil.FALSE_VALUE;
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_NameExpCS_ast_expName_1", e);
}
- return symbol_12;
- } catch (Throwable e) {
- return handleExecutionFailure("MAP_m_NameExpCS_ast_expName_2", e);
+ }
+
+ @Override
+ public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
+ return idResolver.oclEquals(lNameExpCS_5, thoseValues[0]);
}
}
/**
*
- * map m_OperationCS_ast_body in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lOperationCS : minioclcs::OperationCS[1];
- * |)
- * {body : minioclcs::ExpCS[?];
- * |}
- * rightAS ( |)
- * {Variable : miniocl::Variable[1];
- * aOCLExpression : miniocl::OCLExpression[1];
- * aOperation : miniocl::Operation[1];
- * ast : miniocl::Element[1];
- * ast1 : miniocl::Element[1];
- * ownedBodyExpression : miniocl::ExpressionInOCL[1];
- * owningClass : miniocl::Class[?];
- * |}
- * where ( |)
- * { |
- * aOperation := lOperationCS.ast;
- * ast := lOperationCS.ast;
- * body := lOperationCS.body;
- * ast1 := body.ast;
- * owningClass := aOperation.owningClass;
- * Variable := miniocl::Variable{name = 'self', type = owningClass
- * }
+ * map m_NameExpCS_ast_expName_2 in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * var ast : miniocl::Element[1] := lNameExpCS.ast;
+ * var expName : minioclcs::PathNameCS[?] := lNameExpCS.expName;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource()
* ;
- * aOCLExpression := ast1.oclAsType(miniocl::OCLExpression)
+ * check lNameExpCS.isVariableExp()
* ;
- * ownedBodyExpression := miniocl::ExpressionInOCL{ownedBody = aOCLExpression, ownedSelfVar = Variable
- * };
- * aOperation.ownedBodyExpression := ownedBodyExpression;
- * }
+ * var aVariableExp : miniocl::VariableExp[1] := ast.oclAsType(miniocl::VariableExp)
+ * ;
+ * var pathElements : OrderedSet(minioclcs::PathElementCS)[*|1] := expName.pathElements;
+ * var first : minioclcs::PathElementCS[?] := pathElements->first()
+ * ;
+ * var lookupVariable : miniocl::Variable[?] := aVariableExp.lookupVariable(first);
+ * set aVariableExp.referredVariable := lookupVariable;
*
*/
- protected boolean MAP_m_OperationCS_ast_body(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS) {
+ protected boolean MAP_m_NameExpCS_ast_expName_2(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_6) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lOperationCS.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lNameExpCS_6.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aOperation;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Operation;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_12;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Operation symbol_2 = (Operation)ast;
- if (symbol_2 == null) {
- throw throwNull(lOperationCS, "Null where non-null value required");
+ if (ast == null) {
+ throw throwNull(lNameExpCS_6, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_6.getExpName();
+ /*@Caught*/ @Nullable Object CAUGHT_and;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_6.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lOperationCS, "Null where non-null value required");
+ catch (Exception e) {
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_2;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_6);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_1;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_1 = oclAsType;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable ExpCS body = lOperationCS.getBody();
- if (body == null) {
- throw throwNull(lOperationCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CSTrace::ast\'");
+ else {
+ symbol_1 = null;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_1 = body.getAst();
- final /*@Thrown*/ boolean symbol_4 = ast_1 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast1;
- if (symbol_4) {
- if (ast_1 == null) {
- throw throwNull(lOperationCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class owningClass = symbol_2.getOwningClass();
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_name = idResolver.getProperty(PROPid_name);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_type = idResolver.getProperty(PROPid_type);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Variable_0 = idResolver.getClass(CLSSid_Variable, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Variable symbol_7 = (Variable)TYP_miniocl_c_c_Variable_0.createInstance();
- CTORid_name.initValue(symbol_7, STR_self);
- CTORid_type.initValue(symbol_7, owningClass);
- models[1/*rightAS*/].add(symbol_7);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_OCLExpression_0 = idResolver.getClass(CLSSid_OCLExpression, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression oclAsType = ClassUtil.nonNullState((OCLExpression)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_1, TYP_miniocl_c_c_OCLExpression_0));
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_ownedBody = idResolver.getProperty(PROPid_ownedBody);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_ownedSelfVar = idResolver.getProperty(PROPid_ownedSelfVar);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_ExpressionInOCL_0 = idResolver.getClass(CLSSid_ExpressionInOCL, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull ExpressionInOCL symbol_10 = (ExpressionInOCL)TYP_miniocl_c_c_ExpressionInOCL_0.createInstance();
- CTORid_ownedBody.initValue(symbol_10, oclAsType);
- CTORid_ownedSelfVar.initValue(symbol_10, symbol_7);
- models[1/*rightAS*/].add(symbol_10);
- // property assignments
- symbol_2.setOwnedBodyExpression(symbol_10);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OperationCS_ast_body = ValueUtil.TRUE_VALUE;
- raw_ast1 = m_OperationCS_ast_body;
+ final /*@Thrown*/ boolean eq_0 = symbol_1 == null;
+ /*@Thrown*/ boolean symbol_2;
+ if (eq_0) {
+ symbol_2 = ValueUtil.FALSE_VALUE;
}
else {
- raw_ast1 = ValueUtil.FALSE_VALUE;
+ if (symbol_1 == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_1.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_6.equals(navExp);
+ symbol_2 = eq_1;
}
- raw_ast = raw_ast1;
+ CAUGHT_symbol_2 = symbol_2;
}
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_symbol_2 = ValueUtil.createInvalidValue(e);
}
- symbol_12 = raw_ast;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_2);
+ CAUGHT_and = and;
}
- else {
- symbol_12 = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_and = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and);
+ if (not == null) {
+ throw throwNull(lNameExpCS_6, "Null if condition");
}
- raw_aOperation = symbol_12;
- }
- else {
- raw_aOperation = ValueUtil.FALSE_VALUE;
- }
- return raw_aOperation;
- } catch (Throwable e) {
- return handleExecutionFailure("MAP_m_OperationCS_ast_body", e);
- }
- }
-
- /**
- *
- * map m_OperationCS_ast_resultRef in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lOperationCS : minioclcs::OperationCS[1];
- * |)
- * {resultRef : minioclcs::PathNameCS[?];
- * |}
- * rightAS ( |)
- * {aOperation : miniocl::Operation[1];
- * ast : miniocl::Element[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |)
- * { |
- * aOperation := lOperationCS.ast;
- * ast := lOperationCS.ast;
- * resultRef := lOperationCS.resultRef;
- * type := aOperation.lookupClass(resultRef);
- * aOperation.type := type;
- * }
- *
- */
- protected boolean MAP_m_OperationCS_ast_resultRef(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_0) {
- try {
- // predicates and unrealized variables
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lOperationCS_0.getAst();
- final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aOperation;
- if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Operation;
/*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Operation symbol_2 = (Operation)ast;
- if (symbol_2 == null) {
- throw throwNull(lOperationCS_0, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lOperationCS_0, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS resultRef = lOperationCS_0.getResultRef();
- if (resultRef == null) {
- throw throwNull(lOperationCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = resultRef.getPathElements();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
- final /*@Thrown*/ boolean eq = size.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_5;
- if (eq) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS == null) {
- throw throwNull(lOperationCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(symbol_2, (String)elementName);
- org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedClass = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- symbol_5 = _lookupUnqualifiedClass;
- }
- else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
- final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
- assert UNBOXED_qualifierSegments != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = this.lookupPackage(symbol_2, UNBOXED_qualifierSegments);
- /*@Caught*/ @Nullable Object CAUGHT_qualifier;
+ if (not) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_1;
+ try {
+ /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_2;
try {
- CAUGHT_qualifier = qualifier;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_6.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
+ CAUGHT_eq_2 = eq_2;
}
catch (Exception e) {
- CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
- }
- final /*@NonInvalid*/ @NonNull Object symbol_4 = CAUGHT_qualifier == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
- if (symbol_4 == Boolean.TRUE) {
- safe_lookupQualifiedClass_source = null;
+ CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
}
- else {
- if (qualifier == null) {
- throw throwNull(lOperationCS_0, "Null where non-null value required");
+ /*@Caught*/ @Nullable Object CAUGHT_not_0;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_4;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_6);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_3;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_3 = oclAsType_0;
+ }
+ else {
+ symbol_3 = null;
+ }
+ final /*@Thrown*/ boolean eq_3 = symbol_3 == null;
+ /*@Thrown*/ boolean symbol_4;
+ if (eq_3) {
+ symbol_4 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_3 == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_3.getNavExp();
+ final /*@Thrown*/ boolean eq_4 = lNameExpCS_6.equals(navExp_0);
+ symbol_4 = eq_4;
+ }
+ CAUGHT_symbol_4 = symbol_4;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_0 == null) {
- throw throwNull(lOperationCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ catch (Exception e) {
+ CAUGHT_symbol_4 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
- org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
- if (_lookupResult_0.size() == 1) {
- _lookupQualifiedClass = _lookupResult_0.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_0,elementName_0);
- };
- safe_lookupQualifiedClass_source = _lookupQualifiedClass;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_4);
+ CAUGHT_not_0 = not_0;
+ }
+ catch (Exception e) {
+ CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
}
- symbol_5 = safe_lookupQualifiedClass_source;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
+ CAUGHT_and_0 = and_0;
}
- final /*@Thrown*/ boolean symbol_6 = symbol_5 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_type;
- if (symbol_6) {
- if (symbol_5 == null) {
- throw throwNull(lOperationCS_0, "Null where non-null value required");
+ catch (Exception e) {
+ CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_eq_5;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_6.getExpName();
+ if (expName_0 == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
- // property assignments
- symbol_2.setType(symbol_5);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OperationCS_ast_resultRef = ValueUtil.TRUE_VALUE;
- raw_type = m_OperationCS_ast_resultRef;
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
+ final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
+ CAUGHT_eq_5 = eq_5;
}
- else {
- raw_type = ValueUtil.FALSE_VALUE;
+ catch (Exception e) {
+ CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
+ CAUGHT_and_1 = and_1;
+ }
+ catch (Exception e) {
+ CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_ne;
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_6);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
+ if (self_1 == null) {
+ throw throwNull(lNameExpCS_6, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_1 = lNameExpCS_6.getExpName();
+ if (expName_1 == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_1.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
+ Variable _lookupUnqualifiedVariable = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
+ CAUGHT_ne = ne;
+ }
+ catch (Exception e) {
+ CAUGHT_ne = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
+ if (and_2 == null) {
+ throw throwNull(lNameExpCS_6, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
+ if (and_2) {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_VariableExp_0 = idResolver.getClass(CLSSid_VariableExp, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull VariableExp oclAsType_2 = ClassUtil.nonNullState((VariableExp)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_VariableExp_0));
+ if (expName == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_1 = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_1 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_1);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS first = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_1);
+ if (first == null) {
+ throw throwNull(lNameExpCS_6, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = first.getElementName();
+ MiniOCLLookupResult<Variable> _lookupResult_0 = lookupSolver._lookupUnqualifiedVariable(oclAsType_2, (String)elementName_0);
+ Variable _lookupUnqualifiedVariable_0 = null;
+ if (_lookupResult_0.size() == 1) {
+ _lookupUnqualifiedVariable_0 = _lookupResult_0.getSingleResult();
+ } else {
+ handleLookupError(first,elementName_0);
+ };
+ // mapping statements
+ if (_lookupUnqualifiedVariable_0 == null) {
+ throw throwNull(lNameExpCS_6, "Null value for miniocl::VariableExp::referredVariable assignment");
}
- raw_ast = raw_type;
+ oclAsType_2.setReferredVariable(_lookupUnqualifiedVariable_0);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NameExpCS_ast_expName_2 = ValueUtil.TRUE_VALUE;
+ symbol_7 = m_NameExpCS_ast_expName_2;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ symbol_7 = ValueUtil.FALSE_VALUE;
}
- symbol_8 = raw_ast;
+ symbol_8 = symbol_7;
}
else {
symbol_8 = ValueUtil.FALSE_VALUE;
}
- raw_aOperation = symbol_8;
+ raw_ast = symbol_8;
}
else {
- raw_aOperation = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aOperation;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_OperationCS_ast_resultRef", e);
+ return handleExecutionFailure("MAP_m_NameExpCS_ast_expName_2", e);
}
}
/**
*
- * map m_Operation_OperationCS in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lOperationCS : minioclcs::OperationCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rOperation : miniocl::Operation[1];
- * |}
- * where ( |)
- * { |
- * lOperationCS.ast := rOperation;
- * }
+ * map m_NavigationExpCS_ast0 in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lNavigationExpCS : minioclcs::NavigationExpCS[1];
+ * check lNavigationExpCS.oclIsTypeOf(minioclcs::NavigationExpCS);
+ * set lNavigationExpCS.ast := null;
*
*/
- protected boolean MAP_m_Operation_OperationCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_1) {
+ protected boolean MAP_m_NavigationExpCS_ast0(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NavigationExpCS lNavigationExpCS) {
try {
- // predicates and unrealized variables
- // creations
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Operation rOperation = MiniOCLFactory.eINSTANCE.createOperation();
- assert rOperation != null;
- models[1/*rightAS*/].add(rOperation);
- // property assignments
- lOperationCS_1.setAst(rOperation);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Operation_OperationCS = ValueUtil.TRUE_VALUE;
- return m_Operation_OperationCS;
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_NavigationExpCS_0_0 = idResolver.getClass(CLSSid_NavigationExpCS, null);
+ final /*@NonInvalid*/ boolean oclIsTypeOf = OclAnyOclIsTypeOfOperation.INSTANCE.evaluate(executor, lNavigationExpCS, TYP_minioclcs_c_c_NavigationExpCS_0_0).booleanValue();
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_2;
+ if (oclIsTypeOf) {
+ // mapping statements
+ lNavigationExpCS.setAst(null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_NavigationExpCS_ast0 = ValueUtil.TRUE_VALUE;
+ symbol_2 = m_NavigationExpCS_ast0;
+ }
+ else {
+ symbol_2 = ValueUtil.FALSE_VALUE;
+ }
+ return symbol_2;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_Operation_OperationCS", e);
+ return handleExecutionFailure("MAP_m_NavigationExpCS_ast0", e);
}
}
/**
*
- * map m_OrderedSet_ClassCS_2 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lClassCS : minioclcs::ClassCS[1];
- * |)
- * {operations : OrderedSet(minioclcs::OperationCS)[*|1];
- * properties : OrderedSet(minioclcs::PropertyCS)[*|1];
- * |}
- * rightAS ( |)
- * {aClass : miniocl::Class[1];
- * asOrderedSet : OrderedSet(miniocl::Operation)[*|1];
- * asOrderedSet1 : OrderedSet(miniocl::Property)[*|1];
- * ast : miniocl::Element[1];
- * _'\u00ABcollect\u00BB' : Sequence(miniocl::Operation)[*|1];
- * _'\u00ABcollect\u00BB1' : Sequence(miniocl::Property)[*|1];
- * |}
- * where ( |)
- * {name : ecore::EString[?];
- * toString : String[1];
- * |
- * aClass := lClassCS.ast;
- * ast := lClassCS.ast;
- * name := lClassCS.name;
- * operations := lClassCS.operations;
- * properties := lClassCS.properties;
- * toString := name.toString()
- * ;
- * _'\u00ABcollect\u00BB' := operations->collect(_'1_' |
- * _'1_'.ast.oclAsType(miniocl::Operation))
+ * map m_OperationCS_ast_body in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lOperationCS : minioclcs::OperationCS[1];
+ * var ast : miniocl::Element[1] := lOperationCS.ast;
+ * var body : minioclcs::ExpCS[?] := lOperationCS.body;
+ * var aOperation : miniocl::Operation[1] := ast.oclAsType(miniocl::Operation)
* ;
- * _'\u00ABcollect\u00BB1' := properties->collect(_'1_' |
- * _'1_'.ast.oclAsType(miniocl::Property))
+ * var ast1 : miniocl::Element[1] := body.ast;
+ * var aOCLExpression : miniocl::OCLExpression[1] := ast1.oclAsType(miniocl::OCLExpression)
* ;
- * asOrderedSet := _'\u00ABcollect\u00BB'->asOrderedSet()
+ * var owningClass : miniocl::Class[?] := aOperation.owningClass;
+ * var Variable : miniocl::Variable[1] := miniocl::Variable{name = 'self', type = owningClass
+ * }
* ;
- * asOrderedSet1 := _'\u00ABcollect\u00BB1'->asOrderedSet();
- * aClass.name := toString;
- * aClass.ownedOperations := asOrderedSet;
- * aClass.ownedProperties := asOrderedSet1;
- * }
+ * var type : miniocl::Class[1] := aOCLExpression.type;
+ * var ExpressionInOCL : miniocl::ExpressionInOCL[1] := miniocl::ExpressionInOCL{language = 'OCL', ownedBody = aOCLExpression, ownedSelfVar = Variable, type = type
+ * };
+ * set aOperation.ownedBodyExpression := ExpressionInOCL;
*
*/
- protected boolean MAP_m_OrderedSet_ClassCS_2(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS lClassCS_1) {
+ protected boolean MAP_m_OperationCS_ast_body(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lClassCS_1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lOperationCS.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aClass;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof org.eclipse.qvtd.doc.miniocl.Class;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
+ if (ast == null) {
+ throw throwNull(lOperationCS, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable ExpCS body = lOperationCS.getBody();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Operation_0 = idResolver.getClass(CLSSid_Operation, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Operation oclAsType = ClassUtil.nonNullState((Operation)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Operation_0));
+ if (body == null) {
+ throw throwNull(lOperationCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CSTrace::ast\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = body.getAst();
+ final /*@Thrown*/ boolean symbol_1 = ast_0 != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast1;
if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_2 = (org.eclipse.qvtd.doc.miniocl.Class)ast;
- if (symbol_2 == null) {
- throw throwNull(lClassCS_1, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lClassCS_1, "Null where non-null value required");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lClassCS_1.getName();
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<OperationCS> operations = lClassCS_1.getOperations();
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PropertyCS> properties = lClassCS_1.getProperties();
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_operations = idResolver.createOrderedSetOfAll(ORD_CLSSid_OperationCS, operations);
- /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Operation);
- @NonNull Iterator<Object> ITERATOR__1 = BOXED_operations.iterator();
- /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
- while (true) {
- if (!ITERATOR__1.hasNext()) {
- collect = accumulator;
- break;
- }
- @SuppressWarnings("null")
- /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS _1 = (OperationCS)ITERATOR__1.next();
- /**
- * _'1_'.ast.oclAsType(miniocl::Operation)
- */
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Operation_0 = idResolver.getClass(CLSSid_Operation, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_1 = _1.getAst();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Operation oclAsType = ClassUtil.nonNullState((Operation)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_1, TYP_miniocl_c_c_Operation_0));
- //
- accumulator.add(oclAsType);
- }
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_properties = idResolver.createOrderedSetOfAll(ORD_CLSSid_PropertyCS, properties);
- /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator_0 = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Property);
- @NonNull Iterator<Object> ITERATOR__1_0 = BOXED_properties.iterator();
- /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect_0;
- while (true) {
- if (!ITERATOR__1_0.hasNext()) {
- collect_0 = accumulator_0;
- break;
- }
- @SuppressWarnings("null")
- /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS _1_0 = (PropertyCS)ITERATOR__1_0.next();
- /**
- * _'1_'.ast.oclAsType(miniocl::Property)
- */
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Property_0 = idResolver.getClass(CLSSid_Property, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_2 = _1_0.getAst();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property oclAsType_0 = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Property)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_2, TYP_miniocl_c_c_Property_0));
- //
- accumulator_0.add(oclAsType_0);
- }
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet_0 = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect_0);
- // property assignments
- symbol_2.setName(toString);
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Operation> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Operation.class, asOrderedSet);
- symbol_2.getOwnedOperations().addAll(ECORE_asOrderedSet);
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<org.eclipse.qvtd.doc.miniocl.Property> ECORE_asOrderedSet_0 = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(org.eclipse.qvtd.doc.miniocl.Property.class, asOrderedSet_0);
- symbol_2.getOwnedProperties().addAll(ECORE_asOrderedSet_0);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OrderedSet_ClassCS_2 = ValueUtil.TRUE_VALUE;
- raw_ast = m_OrderedSet_ClassCS_2;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (ast_0 == null) {
+ throw throwNull(lOperationCS, "Null where non-null value required");
}
- symbol_7 = raw_ast;
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_OCLExpression_0 = idResolver.getClass(CLSSid_OCLExpression, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull OCLExpression oclAsType_0 = ClassUtil.nonNullState((OCLExpression)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_OCLExpression_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class owningClass = oclAsType.getOwningClass();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_name = idResolver.getProperty(PROPid_name);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_type = idResolver.getProperty(PROPid_type);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Variable_0 = idResolver.getClass(CLSSid_Variable, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Variable symbol_4 = (Variable)TYP_miniocl_c_c_Variable_0.createInstance();
+ CTORid_name.initValue(symbol_4, STR_self);
+ CTORid_type.initValue(symbol_4, owningClass);
+ @SuppressWarnings("null")
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class type = oclAsType_0.getType();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_language = idResolver.getProperty(PROPid_language);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_ownedBody = idResolver.getProperty(PROPid_ownedBody);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Property CTORid_ownedSelfVar = idResolver.getProperty(PROPid_ownedSelfVar);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_ExpressionInOCL_0 = idResolver.getClass(CLSSid_ExpressionInOCL, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull ExpressionInOCL symbol_9 = (ExpressionInOCL)TYP_miniocl_c_c_ExpressionInOCL_0.createInstance();
+ CTORid_language.initValue(symbol_9, STR_OCL);
+ CTORid_ownedBody.initValue(symbol_9, oclAsType_0);
+ CTORid_ownedSelfVar.initValue(symbol_9, symbol_4);
+ CTORid_type.initValue(symbol_9, type);
+ // mapping statements
+ oclAsType.setOwnedBodyExpression(symbol_9);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OperationCS_ast_body = ValueUtil.TRUE_VALUE;
+ raw_ast1 = m_OperationCS_ast_body;
}
else {
- symbol_7 = ValueUtil.FALSE_VALUE;
+ raw_ast1 = ValueUtil.FALSE_VALUE;
+ }
+ raw_ast = raw_ast1;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_OperationCS_ast_body", e);
+ }
+ }
+
+ /**
+ *
+ * map m_OperationCS_ast_name in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lOperationCS : minioclcs::OperationCS[1];
+ * var ast : miniocl::Element[1] := lOperationCS.ast;
+ * var name : ecore::EString[?] := lOperationCS.name;
+ * var aOperation : miniocl::Operation[1] := ast.oclAsType(miniocl::Operation)
+ * ;
+ * set aOperation.name := name.toString();
+ *
+ */
+ protected boolean MAP_m_OperationCS_ast_name(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_0) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lOperationCS_0.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lOperationCS_0, "Null where non-null value required");
}
- raw_aClass = symbol_7;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lOperationCS_0.getName();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Operation_0 = idResolver.getClass(CLSSid_Operation, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Operation oclAsType = ClassUtil.nonNullState((Operation)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Operation_0));
+ // mapping statements
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
+ oclAsType.setName(toString);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OperationCS_ast_name = ValueUtil.TRUE_VALUE;
+ raw_ast = m_OperationCS_ast_name;
}
else {
- raw_aClass = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aClass;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_OrderedSet_ClassCS_2", e);
+ return handleExecutionFailure("MAP_m_OperationCS_ast_name", e);
}
}
/**
*
- * map m_OrderedSet_OperationCS_1 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lOperationCS : minioclcs::OperationCS[1];
- * |)
- * {params : OrderedSet(minioclcs::ParameterCS)[*|1];
- * |}
- * rightAS ( |)
- * {aOperation : miniocl::Operation[1];
- * asOrderedSet : OrderedSet(miniocl::Parameter)[*|1];
- * ast : miniocl::Element[1];
- * _'\u00ABcollect\u00BB' : Sequence(miniocl::Parameter)[*|1];
- * |}
- * where ( |)
- * {name : ecore::EString[?];
- * toString : String[1];
- * |
- * aOperation := lOperationCS.ast;
- * ast := lOperationCS.ast;
- * name := lOperationCS.name;
- * params := lOperationCS.params;
- * toString := name.toString()
+ * map m_OperationCS_ast_params in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lOperationCS : minioclcs::OperationCS[1];
+ * var ast : miniocl::Element[1] := lOperationCS.ast;
+ * var params : OrderedSet(minioclcs::ParameterCS)[*|1] := lOperationCS.params;
+ * var aOperation : miniocl::Operation[1] := ast.oclAsType(miniocl::Operation)
* ;
- * _'\u00ABcollect\u00BB' := params->collect(_'1_' |
+ * var _'\u00ABcollect\u00BB' : Sequence(miniocl::Parameter)[*|1] := params->collect(_'1_' |
* _'1_'.ast.oclAsType(miniocl::Parameter))
* ;
- * asOrderedSet := _'\u00ABcollect\u00BB'->asOrderedSet();
- * aOperation.name := toString;
- * aOperation.ownedParameters := asOrderedSet;
- * }
+ * var asOrderedSet : OrderedSet(miniocl::Parameter)[*|1] := _'\u00ABcollect\u00BB'->asOrderedSet();
+ * set aOperation.ownedParameters := asOrderedSet;
*
*/
- protected boolean MAP_m_OrderedSet_OperationCS_1(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_2) {
+ protected boolean MAP_m_OperationCS_ast_params(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_1) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lOperationCS_1.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lOperationCS_1, "Null where non-null value required");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<ParameterCS> params = lOperationCS_1.getParams();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Operation_0 = idResolver.getClass(CLSSid_Operation, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Operation oclAsType = ClassUtil.nonNullState((Operation)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Operation_0));
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_params = idResolver.createOrderedSetOfAll(ORD_CLSSid_ParameterCS, params);
+ /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Parameter);
+ @NonNull Iterator<Object> ITERATOR__1 = BOXED_params.iterator();
+ /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
+ while (true) {
+ if (!ITERATOR__1.hasNext()) {
+ collect = accumulator;
+ break;
+ }
+ @SuppressWarnings("null")
+ /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS _1 = (ParameterCS)ITERATOR__1.next();
+ /**
+ * _'1_'.ast.oclAsType(miniocl::Parameter)
+ */
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Parameter_0 = idResolver.getClass(CLSSid_Parameter, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = _1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Parameter oclAsType_0 = ClassUtil.nonNullState((Parameter)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_Parameter_0));
+ //
+ accumulator.add(oclAsType_0);
+ }
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
+ // mapping statements
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Parameter> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Parameter.class, asOrderedSet);
+ oclAsType.getOwnedParameters().addAll(ECORE_asOrderedSet);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OperationCS_ast_params = ValueUtil.TRUE_VALUE;
+ raw_ast = m_OperationCS_ast_params;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_OperationCS_ast_params", e);
+ }
+ }
+
+ /**
+ *
+ * map m_OperationCS_ast_resultRef in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lOperationCS : minioclcs::OperationCS[1];
+ * var ast : miniocl::Element[1] := lOperationCS.ast;
+ * var resultRef : minioclcs::PathNameCS[?] := lOperationCS.resultRef;
+ * var aOperation : miniocl::Operation[1] := ast.oclAsType(miniocl::Operation)
+ * ;
+ * var lookupClass : miniocl::Class[?] := aOperation.lookupClass(resultRef);
+ * set aOperation.type := lookupClass;
+ *
+ */
+ protected boolean MAP_m_OperationCS_ast_resultRef(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_2) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lOperationCS_2.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aOperation;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Operation;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_6;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Operation symbol_2 = (Operation)ast;
- if (symbol_2 == null) {
- throw throwNull(lOperationCS_2, "Null where non-null value required");
+ if (ast == null) {
+ throw throwNull(lOperationCS_2, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS resultRef = lOperationCS_2.getResultRef();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Operation_0 = idResolver.getClass(CLSSid_Operation, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Operation oclAsType = ClassUtil.nonNullState((Operation)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Operation_0));
+ if (resultRef == null) {
+ throw throwNull(lOperationCS_2, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = resultRef.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
+ final /*@Thrown*/ boolean eq = size.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_2;
+ if (eq) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lOperationCS_2, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(oclAsType, (String)elementName);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedClass = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ symbol_2 = _lookupUnqualifiedClass;
+ }
+ else {
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
+ final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
+ assert UNBOXED_qualifierSegments != null;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = INST_Visitable_lookupPackage.evaluate(oclAsType, UNBOXED_qualifierSegments);
+ /*@Caught*/ @Nullable Object CAUGHT_qualifier;
+ try {
+ CAUGHT_qualifier = qualifier;
+ }
+ catch (Exception e) {
+ CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
+ final /*@NonInvalid*/ @NonNull Object symbol_1 = CAUGHT_qualifier == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
+ if (symbol_1 == Boolean.TRUE) {
+ safe_lookupQualifiedClass_source = null;
+ }
+ else {
+ if (qualifier == null) {
throw throwNull(lOperationCS_2, "Null where non-null value required");
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lOperationCS_2.getName();
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<ParameterCS> params = lOperationCS_2.getParams();
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_params = idResolver.createOrderedSetOfAll(ORD_CLSSid_ParameterCS, params);
- /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Parameter);
- @NonNull Iterator<Object> ITERATOR__1 = BOXED_params.iterator();
- /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
- while (true) {
- if (!ITERATOR__1.hasNext()) {
- collect = accumulator;
- break;
- }
- @SuppressWarnings("null")
- /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS _1 = (ParameterCS)ITERATOR__1.next();
- /**
- * _'1_'.ast.oclAsType(miniocl::Parameter)
- */
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Parameter_0 = idResolver.getClass(CLSSid_Parameter, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_1 = _1.getAst();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Parameter oclAsType = ClassUtil.nonNullState((Parameter)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_1, TYP_miniocl_c_c_Parameter_0));
- //
- accumulator.add(oclAsType);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS_0 == null) {
+ throw throwNull(lOperationCS_2, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
- // property assignments
- symbol_2.setName(toString);
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Parameter> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Parameter.class, asOrderedSet);
- symbol_2.getOwnedParameters().addAll(ECORE_asOrderedSet);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OrderedSet_OperationCS_1 = ValueUtil.TRUE_VALUE;
- raw_ast = m_OrderedSet_OperationCS_1;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
+ if (_lookupResult_0.size() == 1) {
+ _lookupQualifiedClass = _lookupResult_0.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS_0,elementName_0);
+ };
+ safe_lookupQualifiedClass_source = _lookupQualifiedClass;
}
- symbol_6 = raw_ast;
+ symbol_2 = safe_lookupQualifiedClass_source;
}
- else {
- symbol_6 = ValueUtil.FALSE_VALUE;
+ // mapping statements
+ if (symbol_2 == null) {
+ throw throwNull(lOperationCS_2, "Null value for miniocl::TypedElement::type assignment");
}
- raw_aOperation = symbol_6;
+ oclAsType.setType(symbol_2);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OperationCS_ast_resultRef = ValueUtil.TRUE_VALUE;
+ raw_ast = m_OperationCS_ast_resultRef;
}
else {
- raw_aOperation = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aOperation;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_OrderedSet_OperationCS_1", e);
+ return handleExecutionFailure("MAP_m_OperationCS_ast_resultRef", e);
}
}
/**
*
- * map m_OrderedSet_PackageCS_2 in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lPackageCS : minioclcs::PackageCS[1];
- * |)
- * {classes : OrderedSet(minioclcs::ClassCS)[*|1];
- * packages : OrderedSet(minioclcs::PackageCS)[*|1];
- * |}
- * rightAS ( |)
- * {aPackage : miniocl::Package[1];
- * asOrderedSet : OrderedSet(miniocl::Package)[*|1];
- * asOrderedSet1 : OrderedSet(miniocl::Class)[*|1];
- * ast : miniocl::Element[1];
- * _'\u00ABcollect\u00BB' : Sequence(miniocl::Package)[*|1];
- * _'\u00ABcollect\u00BB1' : Sequence(miniocl::Class)[*|1];
- * |}
- * where ( |)
- * {name : ecore::EString[?];
- * toString : String[1];
- * |
- * aPackage := lPackageCS.ast;
- * ast := lPackageCS.ast;
- * classes := lPackageCS.classes;
- * name := lPackageCS.name;
- * packages := lPackageCS.packages;
- * toString := name.toString()
- * ;
- * _'\u00ABcollect\u00BB' := packages->collect(_'1_' |
- * _'1_'.ast.oclAsType(miniocl::Package))
+ * map m_Operation_OperationCS in MiniOCLCS2AS_qvtp_qvtcas {
+ * guard:leftCS lOperationCS : minioclcs::OperationCS[1];
+ * new:rightAS rOperation : miniocl::Operation[1];
+ * set lOperationCS.ast := rOperation;
+ *
+ */
+ protected boolean MAP_m_Operation_OperationCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull OperationCS lOperationCS_3) {
+ try {
+ // creations
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Operation rOperation = MiniOCLFactory.eINSTANCE.createOperation();
+ assert rOperation != null;
+ models[1/*rightAS*/].add(rOperation);
+ // mapping statements
+ lOperationCS_3.setAst(rOperation);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Operation_OperationCS = ValueUtil.TRUE_VALUE;
+ return m_Operation_OperationCS;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_Operation_OperationCS", e);
+ }
+ }
+
+ /**
+ *
+ * map m_PackageCS_ast_classes in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lPackageCS : minioclcs::PackageCS[1];
+ * var ast : miniocl::Element[1] := lPackageCS.ast;
+ * var classes : OrderedSet(minioclcs::ClassCS)[*|1] := lPackageCS.classes;
+ * var aPackage : miniocl::Package[1] := ast.oclAsType(miniocl::Package)
* ;
- * _'\u00ABcollect\u00BB1' := classes->collect(_'1_' |
+ * var _'\u00ABcollect\u00BB' : Sequence(miniocl::Class)[*|1] := classes->collect(_'1_' |
* _'1_'.ast.oclAsType(miniocl::Class))
* ;
- * asOrderedSet := _'\u00ABcollect\u00BB'->asOrderedSet()
- * ;
- * asOrderedSet1 := _'\u00ABcollect\u00BB1'->asOrderedSet();
- * aPackage.name := toString;
- * aPackage.ownedClasses := asOrderedSet1;
- * aPackage.ownedPackages := asOrderedSet;
- * }
+ * var asOrderedSet : OrderedSet(miniocl::Class)[*|1] := _'\u00ABcollect\u00BB'->asOrderedSet();
+ * set aPackage.ownedClasses := asOrderedSet;
*
*/
- protected boolean MAP_m_OrderedSet_PackageCS_2(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS lPackageCS) {
+ protected boolean MAP_m_PackageCS_ast_classes(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS lPackageCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lPackageCS.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aPackage;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Package;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package symbol_2 = (Package)ast;
- if (symbol_2 == null) {
- throw throwNull(lPackageCS, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lPackageCS, "Null where non-null value required");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<ClassCS> classes = lPackageCS.getClasses();
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lPackageCS.getName();
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PackageCS> packages = lPackageCS.getPackages();
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_packages = idResolver.createOrderedSetOfAll(ORD_CLSSid_PackageCS, packages);
- /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Package);
- @NonNull Iterator<Object> ITERATOR__1 = BOXED_packages.iterator();
- /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
- while (true) {
- if (!ITERATOR__1.hasNext()) {
- collect = accumulator;
- break;
- }
- @SuppressWarnings("null")
- /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS _1 = (PackageCS)ITERATOR__1.next();
- /**
- * _'1_'.ast.oclAsType(miniocl::Package)
- */
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Package_0 = idResolver.getClass(CLSSid_Package, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_1 = _1.getAst();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_1, TYP_miniocl_c_c_Package_0));
- //
- accumulator.add(oclAsType);
- }
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_classes = idResolver.createOrderedSetOfAll(ORD_CLSSid_ClassCS, classes);
- /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator_0 = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Class);
- @NonNull Iterator<Object> ITERATOR__1_0 = BOXED_classes.iterator();
- /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect_0;
- while (true) {
- if (!ITERATOR__1_0.hasNext()) {
- collect_0 = accumulator_0;
- break;
- }
- @SuppressWarnings("null")
- /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS _1_0 = (ClassCS)ITERATOR__1_0.next();
- /**
- * _'1_'.ast.oclAsType(miniocl::Class)
- */
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Class_0 = idResolver.getClass(CLSSid_Class_0, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_2 = _1_0.getAst();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class oclAsType_0 = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Class)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_2, TYP_miniocl_c_c_Class_0));
- //
- accumulator_0.add(oclAsType_0);
- }
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet_0 = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect_0);
- // property assignments
- symbol_2.setName(toString);
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<org.eclipse.qvtd.doc.miniocl.Class> ECORE_asOrderedSet_0 = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(org.eclipse.qvtd.doc.miniocl.Class.class, asOrderedSet_0);
- symbol_2.getOwnedClasses().addAll(ECORE_asOrderedSet_0);
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Package> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Package.class, asOrderedSet);
- symbol_2.getOwnedPackages().addAll(ECORE_asOrderedSet);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OrderedSet_PackageCS_2 = ValueUtil.TRUE_VALUE;
- raw_ast = m_OrderedSet_PackageCS_2;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (ast == null) {
+ throw throwNull(lPackageCS, "Null where non-null value required");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<ClassCS> classes = lPackageCS.getClasses();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Package_0 = idResolver.getClass(CLSSid_Package, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Package_0));
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_classes = idResolver.createOrderedSetOfAll(ORD_CLSSid_ClassCS, classes);
+ /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Class);
+ @NonNull Iterator<Object> ITERATOR__1 = BOXED_classes.iterator();
+ /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
+ while (true) {
+ if (!ITERATOR__1.hasNext()) {
+ collect = accumulator;
+ break;
}
- symbol_7 = raw_ast;
+ @SuppressWarnings("null")
+ /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ClassCS _1 = (ClassCS)ITERATOR__1.next();
+ /**
+ * _'1_'.ast.oclAsType(miniocl::Class)
+ */
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Class_0 = idResolver.getClass(CLSSid_Class_0, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = _1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Class oclAsType_0 = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Class)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_Class_0));
+ //
+ accumulator.add(oclAsType_0);
}
- else {
- symbol_7 = ValueUtil.FALSE_VALUE;
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
+ // mapping statements
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<org.eclipse.qvtd.doc.miniocl.Class> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(org.eclipse.qvtd.doc.miniocl.Class.class, asOrderedSet);
+ oclAsType.getOwnedClasses().addAll(ECORE_asOrderedSet);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PackageCS_ast_classes = ValueUtil.TRUE_VALUE;
+ raw_ast = m_PackageCS_ast_classes;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_PackageCS_ast_classes", e);
+ }
+ }
+
+ /**
+ *
+ * map m_PackageCS_ast_name in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lPackageCS : minioclcs::PackageCS[1];
+ * var ast : miniocl::Element[1] := lPackageCS.ast;
+ * var name : ecore::EString[?] := lPackageCS.name;
+ * var aPackage : miniocl::Package[1] := ast.oclAsType(miniocl::Package)
+ * ;
+ * set aPackage.name := name.toString();
+ *
+ */
+ protected boolean MAP_m_PackageCS_ast_name(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS lPackageCS_0) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lPackageCS_0.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lPackageCS_0, "Null where non-null value required");
}
- raw_aPackage = symbol_7;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lPackageCS_0.getName();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Package_0 = idResolver.getClass(CLSSid_Package, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Package_0));
+ // mapping statements
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
+ oclAsType.setName(toString);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PackageCS_ast_name = ValueUtil.TRUE_VALUE;
+ raw_ast = m_PackageCS_ast_name;
}
else {
- raw_aPackage = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aPackage;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_OrderedSet_PackageCS_2", e);
+ return handleExecutionFailure("MAP_m_PackageCS_ast_name", e);
}
}
/**
*
- * map m_OrderedSet_RootCS in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lRootCS : minioclcs::RootCS[1];
- * |)
- * {packages : OrderedSet(minioclcs::PackageCS)[*|1];
- * |}
- * rightAS ( |)
- * {aRoot : miniocl::Root[1];
- * asOrderedSet : OrderedSet(miniocl::Package)[*|1];
- * ast : miniocl::Element[1];
- * _'\u00ABcollect\u00BB' : Sequence(miniocl::Package)[*|1];
- * |}
- * where ( |)
- * { |
- * aRoot := lRootCS.ast;
- * ast := lRootCS.ast;
- * packages := lRootCS.packages;
- * _'\u00ABcollect\u00BB' := packages->collect(_'1_' |
+ * map m_PackageCS_ast_packages in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lPackageCS : minioclcs::PackageCS[1];
+ * var ast : miniocl::Element[1] := lPackageCS.ast;
+ * var packages : OrderedSet(minioclcs::PackageCS)[*|1] := lPackageCS.packages;
+ * var aPackage : miniocl::Package[1] := ast.oclAsType(miniocl::Package)
+ * ;
+ * var _'\u00ABcollect\u00BB' : Sequence(miniocl::Package)[*|1] := packages->collect(_'1_' |
* _'1_'.ast.oclAsType(miniocl::Package))
* ;
- * asOrderedSet := _'\u00ABcollect\u00BB'->asOrderedSet();
- * aRoot.ownedPackages := asOrderedSet;
- * }
+ * var asOrderedSet : OrderedSet(miniocl::Package)[*|1] := _'\u00ABcollect\u00BB'->asOrderedSet();
+ * set aPackage.ownedPackages := asOrderedSet;
*
*/
- protected boolean MAP_m_OrderedSet_RootCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS lRootCS) {
+ protected boolean MAP_m_PackageCS_ast_packages(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS lPackageCS_1) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lRootCS.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lPackageCS_1.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aRoot;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Root;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_5;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Root symbol_2 = (Root)ast;
- if (symbol_2 == null) {
- throw throwNull(lRootCS, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lRootCS, "Null where non-null value required");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PackageCS> packages = lRootCS.getPackages();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_packages = idResolver.createOrderedSetOfAll(ORD_CLSSid_PackageCS, packages);
- /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Package);
- @NonNull Iterator<Object> ITERATOR__1 = BOXED_packages.iterator();
- /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
- while (true) {
- if (!ITERATOR__1.hasNext()) {
- collect = accumulator;
- break;
- }
- @SuppressWarnings("null")
- /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS _1 = (PackageCS)ITERATOR__1.next();
- /**
- * _'1_'.ast.oclAsType(miniocl::Package)
- */
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Package_0 = idResolver.getClass(CLSSid_Package, null);
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_1 = _1.getAst();
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_1, TYP_miniocl_c_c_Package_0));
- //
- accumulator.add(oclAsType);
- }
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
- // property assignments
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Package> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Package.class, asOrderedSet);
- symbol_2.getOwnedPackages().addAll(ECORE_asOrderedSet);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_OrderedSet_RootCS = ValueUtil.TRUE_VALUE;
- raw_ast = m_OrderedSet_RootCS;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
- }
- symbol_5 = raw_ast;
+ if (ast == null) {
+ throw throwNull(lPackageCS_1, "Null where non-null value required");
}
- else {
- symbol_5 = ValueUtil.FALSE_VALUE;
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PackageCS> packages = lPackageCS_1.getPackages();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Package_0 = idResolver.getClass(CLSSid_Package, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Package_0));
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_packages = idResolver.createOrderedSetOfAll(ORD_CLSSid_PackageCS, packages);
+ /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Package);
+ @NonNull Iterator<Object> ITERATOR__1 = BOXED_packages.iterator();
+ /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
+ while (true) {
+ if (!ITERATOR__1.hasNext()) {
+ collect = accumulator;
+ break;
+ }
+ @SuppressWarnings("null")
+ /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS _1 = (PackageCS)ITERATOR__1.next();
+ /**
+ * _'1_'.ast.oclAsType(miniocl::Package)
+ */
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = _1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType_0 = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_Package_0));
+ //
+ accumulator.add(oclAsType_0);
}
- raw_aRoot = symbol_5;
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
+ // mapping statements
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Package> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Package.class, asOrderedSet);
+ oclAsType.getOwnedPackages().addAll(ECORE_asOrderedSet);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PackageCS_ast_packages = ValueUtil.TRUE_VALUE;
+ raw_ast = m_PackageCS_ast_packages;
}
else {
- raw_aRoot = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aRoot;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_OrderedSet_RootCS", e);
+ return handleExecutionFailure("MAP_m_PackageCS_ast_packages", e);
}
}
/**
*
- * map m_Package_PackageCS in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lPackageCS : minioclcs::PackageCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rPackage : miniocl::Package[1];
- * |}
- * where ( |)
- * { |
- * lPackageCS.ast := rPackage;
- * }
+ * map m_Package_PackageCS in MiniOCLCS2AS_qvtp_qvtcas {
+ * guard:leftCS lPackageCS : minioclcs::PackageCS[1];
+ * new:rightAS rPackage : miniocl::Package[1];
+ * set lPackageCS.ast := rPackage;
*
*/
- protected boolean MAP_m_Package_PackageCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS lPackageCS_0) {
+ protected boolean MAP_m_Package_PackageCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS lPackageCS_2) {
try {
- // predicates and unrealized variables
// creations
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package rPackage = MiniOCLFactory.eINSTANCE.createPackage();
assert rPackage != null;
models[1/*rightAS*/].add(rPackage);
- // property assignments
- lPackageCS_0.setAst(rPackage);
+ // mapping statements
+ lPackageCS_2.setAst(rPackage);
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Package_PackageCS = ValueUtil.TRUE_VALUE;
return m_Package_PackageCS;
} catch (Throwable e) {
@@ -3890,141 +3528,144 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
- * map m_ParameterCS_ast_typeRef in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lParameterCS : minioclcs::ParameterCS[1];
- * |)
- * {typeRef : minioclcs::PathNameCS[?];
- * |}
- * rightAS ( |)
- * {aParameter : miniocl::Parameter[1];
- * ast : miniocl::Element[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |)
- * { |
- * aParameter := lParameterCS.ast;
- * ast := lParameterCS.ast;
- * typeRef := lParameterCS.typeRef;
- * type := aParameter.lookupClass(typeRef);
- * aParameter.type := type;
- * }
+ * map m_ParameterCS_ast_name in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lParameterCS : minioclcs::ParameterCS[1];
+ * var ast : miniocl::Element[1] := lParameterCS.ast;
+ * var name : ecore::EString[?] := lParameterCS.name;
+ * var aParameter : miniocl::Parameter[1] := ast.oclAsType(miniocl::Parameter)
+ * ;
+ * set aParameter.name := name.toString();
*
*/
- protected boolean MAP_m_ParameterCS_ast_typeRef(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS lParameterCS) {
+ protected boolean MAP_m_ParameterCS_ast_name(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS lParameterCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lParameterCS.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aParameter;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Parameter;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Parameter symbol_2 = (Parameter)ast;
- if (symbol_2 == null) {
- throw throwNull(lParameterCS, "Null where non-null value required");
+ if (ast == null) {
+ throw throwNull(lParameterCS, "Null where non-null value required");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lParameterCS.getName();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Parameter_0 = idResolver.getClass(CLSSid_Parameter, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Parameter oclAsType = ClassUtil.nonNullState((Parameter)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Parameter_0));
+ // mapping statements
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
+ oclAsType.setName(toString);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ParameterCS_ast_name = ValueUtil.TRUE_VALUE;
+ raw_ast = m_ParameterCS_ast_name;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_ParameterCS_ast_name", e);
+ }
+ }
+
+ /**
+ *
+ * map m_ParameterCS_ast_typeRef in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lParameterCS : minioclcs::ParameterCS[1];
+ * var ast : miniocl::Element[1] := lParameterCS.ast;
+ * var typeRef : minioclcs::PathNameCS[?] := lParameterCS.typeRef;
+ * var aParameter : miniocl::Parameter[1] := ast.oclAsType(miniocl::Parameter)
+ * ;
+ * var lookupClass : miniocl::Class[?] := aParameter.lookupClass(typeRef);
+ * set aParameter.type := lookupClass;
+ *
+ */
+ protected boolean MAP_m_ParameterCS_ast_typeRef(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS lParameterCS_0) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lParameterCS_0.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lParameterCS_0, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS typeRef = lParameterCS_0.getTypeRef();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Parameter_0 = idResolver.getClass(CLSSid_Parameter, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Parameter oclAsType = ClassUtil.nonNullState((Parameter)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Parameter_0));
+ if (typeRef == null) {
+ throw throwNull(lParameterCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = typeRef.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
+ final /*@Thrown*/ boolean eq = size.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_2;
+ if (eq) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lParameterCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lParameterCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS typeRef = lParameterCS.getTypeRef();
- if (typeRef == null) {
- throw throwNull(lParameterCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = typeRef.getPathElements();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
- final /*@Thrown*/ boolean eq = size.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_5;
- if (eq) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS == null) {
- throw throwNull(lParameterCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(symbol_2, (String)elementName);
- org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedClass = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- symbol_5 = _lookupUnqualifiedClass;
- }
- else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
- final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
- assert UNBOXED_qualifierSegments != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = this.lookupPackage(symbol_2, UNBOXED_qualifierSegments);
- /*@Caught*/ @Nullable Object CAUGHT_qualifier;
- try {
- CAUGHT_qualifier = qualifier;
- }
- catch (Exception e) {
- CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
- }
- final /*@NonInvalid*/ @NonNull Object symbol_4 = CAUGHT_qualifier == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
- if (symbol_4 == Boolean.TRUE) {
- safe_lookupQualifiedClass_source = null;
- }
- else {
- if (qualifier == null) {
- throw throwNull(lParameterCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_0 == null) {
- throw throwNull(lParameterCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
- org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
- if (_lookupResult_0.size() == 1) {
- _lookupQualifiedClass = _lookupResult_0.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_0,elementName_0);
- };
- safe_lookupQualifiedClass_source = _lookupQualifiedClass;
- }
- symbol_5 = safe_lookupQualifiedClass_source;
- }
- final /*@Thrown*/ boolean symbol_6 = symbol_5 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_type;
- if (symbol_6) {
- if (symbol_5 == null) {
- throw throwNull(lParameterCS, "Null where non-null value required");
- }
- // property assignments
- symbol_2.setType(symbol_5);
- objectManager.assigned(symbol_2, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, symbol_5, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ParameterCS_ast_typeRef = ValueUtil.TRUE_VALUE;
- raw_type = m_ParameterCS_ast_typeRef;
- }
- else {
- raw_type = ValueUtil.FALSE_VALUE;
- }
- raw_ast = raw_type;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(oclAsType, (String)elementName);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedClass = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ symbol_2 = _lookupUnqualifiedClass;
+ }
+ else {
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
+ final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
+ assert UNBOXED_qualifierSegments != null;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = INST_Visitable_lookupPackage.evaluate(oclAsType, UNBOXED_qualifierSegments);
+ /*@Caught*/ @Nullable Object CAUGHT_qualifier;
+ try {
+ CAUGHT_qualifier = qualifier;
+ }
+ catch (Exception e) {
+ CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
+ }
+ final /*@NonInvalid*/ @NonNull Object symbol_1 = CAUGHT_qualifier == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
+ if (symbol_1 == Boolean.TRUE) {
+ safe_lookupQualifiedClass_source = null;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (qualifier == null) {
+ throw throwNull(lParameterCS_0, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS_0 == null) {
+ throw throwNull(lParameterCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
+ if (_lookupResult_0.size() == 1) {
+ _lookupQualifiedClass = _lookupResult_0.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS_0,elementName_0);
+ };
+ safe_lookupQualifiedClass_source = _lookupQualifiedClass;
}
- symbol_8 = raw_ast;
+ symbol_2 = safe_lookupQualifiedClass_source;
}
- else {
- symbol_8 = ValueUtil.FALSE_VALUE;
+ // mapping statements
+ if (symbol_2 == null) {
+ throw throwNull(lParameterCS_0, "Null value for miniocl::TypedElement::type assignment");
}
- raw_aParameter = symbol_8;
+ oclAsType.setType(symbol_2);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_ParameterCS_ast_typeRef = ValueUtil.TRUE_VALUE;
+ raw_ast = m_ParameterCS_ast_typeRef;
}
else {
- raw_aParameter = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aParameter;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_ParameterCS_ast_typeRef", e);
}
@@ -4032,27 +3673,20 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
- * map m_Parameter_ParameterCS in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lParameterCS : minioclcs::ParameterCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rParameter : miniocl::Parameter[1];
- * |}
- * where ( |)
- * { |
- * lParameterCS.ast := rParameter;
- * }
+ * map m_Parameter_ParameterCS in MiniOCLCS2AS_qvtp_qvtcas {
+ * guard:leftCS lParameterCS : minioclcs::ParameterCS[1];
+ * new:rightAS rParameter : miniocl::Parameter[1];
+ * set lParameterCS.ast := rParameter;
*
*/
- protected boolean MAP_m_Parameter_ParameterCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS lParameterCS_0) {
+ protected boolean MAP_m_Parameter_ParameterCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS lParameterCS_1) {
try {
- // predicates and unrealized variables
// creations
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Parameter rParameter = MiniOCLFactory.eINSTANCE.createParameter();
assert rParameter != null;
models[1/*rightAS*/].add(rParameter);
- // property assignments
- lParameterCS_0.setAst(rParameter);
+ // mapping statements
+ lParameterCS_1.setAst(rParameter);
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Parameter_ParameterCS = ValueUtil.TRUE_VALUE;
return m_Parameter_ParameterCS;
} catch (Throwable e) {
@@ -4062,141 +3696,144 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
- * map m_PropertyCS_ast_typeRef in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lPropertyCS : minioclcs::PropertyCS[1];
- * |)
- * {typeRef : minioclcs::PathNameCS[?];
- * |}
- * rightAS ( |)
- * {aProperty : miniocl::Property[1];
- * ast : miniocl::Element[1];
- * type : miniocl::Class[1];
- * |}
- * where ( |)
- * { |
- * aProperty := lPropertyCS.ast;
- * ast := lPropertyCS.ast;
- * typeRef := lPropertyCS.typeRef;
- * type := aProperty.lookupClass(typeRef);
- * aProperty.type := type;
- * }
+ * map m_PropertyCS_ast_name in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lPropertyCS : minioclcs::PropertyCS[1];
+ * var ast : miniocl::Element[1] := lPropertyCS.ast;
+ * var name : ecore::EString[?] := lPropertyCS.name;
+ * var aProperty : miniocl::Property[1] := ast.oclAsType(miniocl::Property)
+ * ;
+ * set aProperty.name := name.toString();
*
*/
- protected boolean MAP_m_PropertyCS_ast_typeRef(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS lPropertyCS) {
+ protected boolean MAP_m_PropertyCS_ast_name(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS lPropertyCS) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lPropertyCS.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aProperty;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof org.eclipse.qvtd.doc.miniocl.Property;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property symbol_2 = (org.eclipse.qvtd.doc.miniocl.Property)ast;
- if (symbol_2 == null) {
- throw throwNull(lPropertyCS, "Null where non-null value required");
+ if (ast == null) {
+ throw throwNull(lPropertyCS, "Null where non-null value required");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lPropertyCS.getName();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Property_0 = idResolver.getClass(CLSSid_Property, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property oclAsType = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Property)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Property_0));
+ // mapping statements
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
+ oclAsType.setName(toString);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCS_ast_name = ValueUtil.TRUE_VALUE;
+ raw_ast = m_PropertyCS_ast_name;
+ }
+ else {
+ raw_ast = ValueUtil.FALSE_VALUE;
+ }
+ return raw_ast;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_PropertyCS_ast_name", e);
+ }
+ }
+
+ /**
+ *
+ * map m_PropertyCS_ast_typeRef in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lPropertyCS : minioclcs::PropertyCS[1];
+ * var ast : miniocl::Element[1] := lPropertyCS.ast;
+ * var typeRef : minioclcs::PathNameCS[?] := lPropertyCS.typeRef;
+ * var aProperty : miniocl::Property[1] := ast.oclAsType(miniocl::Property)
+ * ;
+ * var lookupClass : miniocl::Class[?] := aProperty.lookupClass(typeRef);
+ * set aProperty.type := lookupClass;
+ *
+ */
+ protected boolean MAP_m_PropertyCS_ast_typeRef(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS lPropertyCS_0) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lPropertyCS_0.getAst();
+ final /*@Thrown*/ boolean symbol_0 = ast != null;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
+ if (symbol_0) {
+ if (ast == null) {
+ throw throwNull(lPropertyCS_0, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS typeRef = lPropertyCS_0.getTypeRef();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Property_0 = idResolver.getClass(CLSSid_Property, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Property oclAsType = ClassUtil.nonNullState((org.eclipse.qvtd.doc.miniocl.Property)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Property_0));
+ if (typeRef == null) {
+ throw throwNull(lPropertyCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = typeRef.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
+ final /*@Thrown*/ boolean eq = size.equals(INT_1);
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_2;
+ if (eq) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lPropertyCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lPropertyCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS typeRef = lPropertyCS.getTypeRef();
- if (typeRef == null) {
- throw throwNull(lPropertyCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
- }
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> segments_0 = typeRef.getPathElements();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_segments_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, segments_0);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_segments_0);
- final /*@Thrown*/ boolean eq = size.equals(INT_1);
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class symbol_5;
- if (eq) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS == null) {
- throw throwNull(lPropertyCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(symbol_2, (String)elementName);
- org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedClass = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- symbol_5 = _lookupUnqualifiedClass;
- }
- else {
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
- final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
- assert UNBOXED_qualifierSegments != null;
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = this.lookupPackage(symbol_2, UNBOXED_qualifierSegments);
- /*@Caught*/ @Nullable Object CAUGHT_qualifier;
- try {
- CAUGHT_qualifier = qualifier;
- }
- catch (Exception e) {
- CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
- }
- final /*@NonInvalid*/ @NonNull Object symbol_4 = CAUGHT_qualifier == null;
- /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
- if (symbol_4 == Boolean.TRUE) {
- safe_lookupQualifiedClass_source = null;
- }
- else {
- if (qualifier == null) {
- throw throwNull(lPropertyCS, "Null where non-null value required");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
- if (aPathElementCS_0 == null) {
- throw throwNull(lPropertyCS, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
- MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
- org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
- if (_lookupResult_0.size() == 1) {
- _lookupQualifiedClass = _lookupResult_0.getSingleResult();
- } else {
- handleLookupError(aPathElementCS_0,elementName_0);
- };
- safe_lookupQualifiedClass_source = _lookupQualifiedClass;
- }
- symbol_5 = safe_lookupQualifiedClass_source;
- }
- final /*@Thrown*/ boolean symbol_6 = symbol_5 != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_type;
- if (symbol_6) {
- if (symbol_5 == null) {
- throw throwNull(lPropertyCS, "Null where non-null value required");
- }
- // property assignments
- symbol_2.setType(symbol_5);
- objectManager.assigned(symbol_2, MiniOCLPackage.Literals.TYPED_ELEMENT__TYPE, symbol_5, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCS_ast_typeRef = ValueUtil.TRUE_VALUE;
- raw_type = m_PropertyCS_ast_typeRef;
- }
- else {
- raw_type = ValueUtil.FALSE_VALUE;
- }
- raw_ast = raw_type;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult = lookupSolver._lookupUnqualifiedClass(oclAsType, (String)elementName);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupUnqualifiedClass = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedClass = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ symbol_2 = _lookupUnqualifiedClass;
+ }
+ else {
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue diff = (IntegerValue)NumericMinusOperation.INSTANCE.evaluate(size, INT_1);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue qualifierSegments = OrderedSetSubOrderedSetOperation.INSTANCE.evaluate(BOXED_segments_0, INT_1, diff);
+ final List<PathElementCS> UNBOXED_qualifierSegments = qualifierSegments.asEcoreObjects(idResolver, PathElementCS.class);
+ assert UNBOXED_qualifierSegments != null;
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Package qualifier = INST_Visitable_lookupPackage.evaluate(oclAsType, UNBOXED_qualifierSegments);
+ /*@Caught*/ @Nullable Object CAUGHT_qualifier;
+ try {
+ CAUGHT_qualifier = qualifier;
+ }
+ catch (Exception e) {
+ CAUGHT_qualifier = ValueUtil.createInvalidValue(e);
+ }
+ final /*@NonInvalid*/ @NonNull Object symbol_1 = CAUGHT_qualifier == null;
+ /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Class safe_lookupQualifiedClass_source;
+ if (symbol_1 == Boolean.TRUE) {
+ safe_lookupQualifiedClass_source = null;
}
else {
- raw_ast = ValueUtil.FALSE_VALUE;
+ if (qualifier == null) {
+ throw throwNull(lPropertyCS_0, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS_0 = (PathElementCS)OrderedCollectionLastOperation.INSTANCE.evaluate(BOXED_segments_0);
+ if (aPathElementCS_0 == null) {
+ throw throwNull(lPropertyCS_0, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName_0 = aPathElementCS_0.getElementName();
+ MiniOCLLookupResult<org.eclipse.qvtd.doc.miniocl.Class> _lookupResult_0 = lookupSolver._lookupQualifiedClass(qualifier, (String)elementName_0);
+ org.eclipse.qvtd.doc.miniocl.Class _lookupQualifiedClass = null;
+ if (_lookupResult_0.size() == 1) {
+ _lookupQualifiedClass = _lookupResult_0.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS_0,elementName_0);
+ };
+ safe_lookupQualifiedClass_source = _lookupQualifiedClass;
}
- symbol_8 = raw_ast;
+ symbol_2 = safe_lookupQualifiedClass_source;
}
- else {
- symbol_8 = ValueUtil.FALSE_VALUE;
+ // mapping statements
+ if (symbol_2 == null) {
+ throw throwNull(lPropertyCS_0, "Null value for miniocl::TypedElement::type assignment");
}
- raw_aProperty = symbol_8;
+ oclAsType.setType(symbol_2);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCS_ast_typeRef = ValueUtil.TRUE_VALUE;
+ raw_ast = m_PropertyCS_ast_typeRef;
}
else {
- raw_aProperty = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aProperty;
+ return raw_ast;
} catch (Throwable e) {
return handleExecutionFailure("MAP_m_PropertyCS_ast_typeRef", e);
}
@@ -4204,23 +3841,16 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
- * map m_PropertyCallExp_NameExpCS in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rPropertyCallExp : miniocl::PropertyCallExp[1];
- * |}
- * where ( |
- * lNameExpCS.isPropCallExpWithExplicitSource())
- * { |
- * lNameExpCS.ast := rPropertyCallExp;
- * }
+ * map m_PropertyCallExp_NameExpCS_Boolean in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * check lNameExpCS.isPropCallExpWithExplicitSource();
+ * new:rightAS rPropertyCallExp : miniocl::PropertyCallExp[1];
+ * notify set lNameExpCS.ast := rPropertyCallExp;
*
*/
- protected boolean MAP_m_PropertyCallExp_NameExpCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_7) {
+ protected boolean MAP_m_PropertyCallExp_NameExpCS_Boolean(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_7) {
try {
- // predicates and unrealized variables
final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
/*@Caught*/ @NonNull Object CAUGHT_eq;
try {
@@ -4251,10 +3881,10 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
}
else {
if (symbol_0 == null) {
- throw throwNull(lNameExpCS_7, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ throw throwNull(lNameExpCS_7, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_7.equals(nameExp);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_0.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_7.equals(navExp);
symbol_1 = eq_1;
}
CAUGHT_symbol_1 = symbol_1;
@@ -4266,57 +3896,46 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
if (and == null) {
throw throwNull(lNameExpCS_7, "Null if condition");
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_3;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_4;
if (and) {
// creations
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp rPropertyCallExp = MiniOCLFactory.eINSTANCE.createPropertyCallExp();
assert rPropertyCallExp != null;
models[1/*rightAS*/].add(rPropertyCallExp);
- // property assignments
+ // mapping statements
lNameExpCS_7.setAst(rPropertyCallExp);
objectManager.assigned(lNameExpCS_7, MinioclcsPackage.Literals.CS_TRACE__AST, rPropertyCallExp, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCallExp_NameExpCS = ValueUtil.TRUE_VALUE;
- symbol_3 = m_PropertyCallExp_NameExpCS;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCallExp_NameExpCS_Boolean = ValueUtil.TRUE_VALUE;
+ symbol_4 = m_PropertyCallExp_NameExpCS_Boolean;
}
else {
- symbol_3 = ValueUtil.FALSE_VALUE;
+ symbol_4 = ValueUtil.FALSE_VALUE;
}
- return symbol_3;
+ return symbol_4;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_PropertyCallExp_NameExpCS", e);
+ return handleExecutionFailure("MAP_m_PropertyCallExp_NameExpCS_Boolean", e);
}
}
/**
*
- * map m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rPropertyCallExp : miniocl::PropertyCallExp[1];
- * |}
- * where ( |
- * not lNameExpCS.isVariableExp()
- * lNameExpCS.isPropCallExpWithImplicitSource()
- * not lNameExpCS.isPropCallExpWithExplicitSource())
- * { |
- * lNameExpCS.ast := rPropertyCallExp;
- * }
+ * map m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * check not lNameExpCS.isVariableExp()
+ * ;
+ * check lNameExpCS.isPropCallExpWithImplicitSource()
+ * ;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource();
+ * new:rightAS rPropertyCallExp : miniocl::PropertyCallExp[1];
+ * notify set lNameExpCS.ast := rPropertyCallExp;
*
*/
- protected class MAP_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr extends AbstractInvocation
- {
- protected final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_8;
-
- public MAP_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr(@NonNull Object @NonNull [] boundValues) {
- lNameExpCS_8 = (NameExpCS)boundValues[0];
- }
-
- public boolean execute() {
+ protected boolean MAP_m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_8) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ /*@Caught*/ @Nullable Object CAUGHT_and_1;
try {
- // predicates and unrealized variables
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
/*@Caught*/ @Nullable Object CAUGHT_and_0;
try {
/*@Caught*/ @Nullable Object CAUGHT_and;
@@ -4332,31 +3951,38 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
}
/*@Caught*/ @Nullable Object CAUGHT_not;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_8);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_8);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_0 = oclAsType;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_8.equals(nameExp);
- symbol_1 = eq_1;
+ else {
+ symbol_0 = null;
+ }
+ final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
+ /*@Thrown*/ boolean symbol_1;
+ if (eq_0) {
+ symbol_1 = ValueUtil.FALSE_VALUE;
+ }
+ else {
+ if (symbol_0 == null) {
+ throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_0.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_8.equals(navExp);
+ symbol_1 = eq_1;
+ }
+ CAUGHT_symbol_1 = symbol_1;
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(symbol_1);
+ catch (Exception e) {
+ CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_1);
CAUGHT_not = not;
}
catch (Exception e) {
@@ -4372,12 +3998,12 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
try {
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_8.getExpName();
if (expName == null) {
- throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
@SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
CAUGHT_eq_2 = eq_2;
}
@@ -4401,12 +4027,12 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
}
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_8.getExpName();
if (expName_0 == null) {
- throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
}
@SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
if (aPathElementCS == null) {
throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
}
@@ -4425,22 +4051,29 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
CAUGHT_ne = ValueUtil.createInvalidValue(e);
}
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_ne);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(and_1);
- if (not_0 == null) {
- throw throwNull(lNameExpCS_8, "Null if condition");
+ CAUGHT_and_1 = and_1;
+ }
+ catch (Exception e) {
+ CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_1);
+ if (not_0 == null) {
+ throw throwNull(lNameExpCS_8, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_10;
+ if (not_0) {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_3;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_8.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_3 = roundedBrackets_0 == null;
+ CAUGHT_eq_3 = eq_3;
}
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_9;
- if (not_0) {
- /*@Caught*/ @NonNull Object CAUGHT_eq_3;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_8.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_3 = roundedBrackets_0 == null;
- CAUGHT_eq_3 = eq_3;
- }
- catch (Exception e) {
- CAUGHT_eq_3 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @Nullable Object CAUGHT_not_1;
+ catch (Exception e) {
+ CAUGHT_eq_3 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @Nullable Object CAUGHT_not_1;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_3;
try {
final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_8);
final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
@@ -4460,24 +4093,31 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
}
else {
if (symbol_2 == null) {
- throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_5 = lNameExpCS_8.equals(nameExp_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_2.getNavExp();
+ final /*@Thrown*/ boolean eq_5 = lNameExpCS_8.equals(navExp_0);
symbol_3 = eq_5;
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(symbol_3);
- CAUGHT_not_1 = not_1;
+ CAUGHT_symbol_3 = symbol_3;
}
catch (Exception e) {
- CAUGHT_not_1 = ValueUtil.createInvalidValue(e);
+ CAUGHT_symbol_3 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_3, CAUGHT_not_1);
- if (and_2 == null) {
- throw throwNull(lNameExpCS_8, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
- if (and_2) {
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_1 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_3);
+ CAUGHT_not_1 = not_1;
+ }
+ catch (Exception e) {
+ CAUGHT_not_1 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_3, CAUGHT_not_1);
+ if (and_2 == null) {
+ throw throwNull(lNameExpCS_8, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_9;
+ if (and_2) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_3;
+ try {
/*@Caught*/ @NonNull Object CAUGHT_eq_6;
try {
final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_1 = lNameExpCS_8.getRoundedBrackets();
@@ -4507,10 +4147,10 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
}
else {
if (symbol_4 == null) {
- throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
+ throw throwNull(lNameExpCS_8, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_1 = symbol_4.getNameExp();
- final /*@Thrown*/ boolean eq_8 = lNameExpCS_8.equals(nameExp_1);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_1 = symbol_4.getNavExp();
+ final /*@Thrown*/ boolean eq_8 = lNameExpCS_8.equals(navExp_1);
symbol_5 = eq_8;
}
CAUGHT_symbol_5 = symbol_5;
@@ -4519,26 +4159,26 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
CAUGHT_symbol_5 = ValueUtil.createInvalidValue(e);
}
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_3 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_6, CAUGHT_symbol_5);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(and_3);
- if (not_2 == null) {
- throw throwNull(lNameExpCS_8, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
- if (not_2) {
- // creations
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp rPropertyCallExp = MiniOCLFactory.eINSTANCE.createPropertyCallExp();
- assert rPropertyCallExp != null;
- models[1/*rightAS*/].add(rPropertyCallExp);
- // property assignments
- lNameExpCS_8.setAst(rPropertyCallExp);
- objectManager.assigned(lNameExpCS_8, MinioclcsPackage.Literals.CS_TRACE__AST, rPropertyCallExp, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr = ValueUtil.TRUE_VALUE;
- symbol_7 = m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr;
- }
- else {
- symbol_7 = ValueUtil.FALSE_VALUE;
- }
- symbol_8 = symbol_7;
+ CAUGHT_and_3 = and_3;
+ }
+ catch (Exception e) {
+ CAUGHT_and_3 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_2 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_3);
+ if (not_2 == null) {
+ throw throwNull(lNameExpCS_8, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_8;
+ if (not_2) {
+ // creations
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable PropertyCallExp rPropertyCallExp = MiniOCLFactory.eINSTANCE.createPropertyCallExp();
+ assert rPropertyCallExp != null;
+ models[1/*rightAS*/].add(rPropertyCallExp);
+ // mapping statements
+ lNameExpCS_8.setAst(rPropertyCallExp);
+ objectManager.assigned(lNameExpCS_8, MinioclcsPackage.Literals.CS_TRACE__AST, rPropertyCallExp, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El = ValueUtil.TRUE_VALUE;
+ symbol_8 = m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El;
}
else {
symbol_8 = ValueUtil.FALSE_VALUE;
@@ -4548,40 +4188,33 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
else {
symbol_9 = ValueUtil.FALSE_VALUE;
}
- return symbol_9;
- } catch (Throwable e) {
- return handleExecutionFailure("MAP_m_PropertyCallExp_NameExpCS_CallExpCS_Element_Expr", e);
+ symbol_10 = symbol_9;
}
- }
-
- public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
- return idResolver.oclEquals(lNameExpCS_8, thoseValues[0]);
+ else {
+ symbol_10 = ValueUtil.FALSE_VALUE;
+ }
+ return symbol_10;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_PropertyCallExp_NameExpCS_CallExpCS_CallExpCS_El", e);
}
}
/**
*
- * map m_Property_PropertyCS in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lPropertyCS : minioclcs::PropertyCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rProperty : miniocl::Property[1];
- * |}
- * where ( |)
- * { |
- * lPropertyCS.ast := rProperty;
- * }
+ * map m_Property_PropertyCS in MiniOCLCS2AS_qvtp_qvtcas {
+ * guard:leftCS lPropertyCS : minioclcs::PropertyCS[1];
+ * new:rightAS rProperty : miniocl::Property[1];
+ * set lPropertyCS.ast := rProperty;
*
*/
- protected boolean MAP_m_Property_PropertyCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS lPropertyCS_0) {
+ protected boolean MAP_m_Property_PropertyCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS lPropertyCS_1) {
try {
- // predicates and unrealized variables
// creations
final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property rProperty = MiniOCLFactory.eINSTANCE.createProperty();
assert rProperty != null;
models[1/*rightAS*/].add(rProperty);
- // property assignments
- lPropertyCS_0.setAst(rProperty);
+ // mapping statements
+ lPropertyCS_1.setAst(rProperty);
final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Property_PropertyCS = ValueUtil.TRUE_VALUE;
return m_Property_PropertyCS;
} catch (Throwable e) {
@@ -4591,385 +4224,303 @@ public class MiniOCLCS2AS_qvtp_qvtcas extends AbstractCS2ASTransformer
/**
*
- * map m_Root_RootCS in MiniOCLCS2AS_qvtp_qvtcas {leftCS (lRootCS : minioclcs::RootCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rRoot : miniocl::Root[1];
- * |}
- * where ( |)
- * { |
- * lRootCS.ast := rRoot;
- * }
+ * map m_RootCS_ast_packages in MiniOCLCS2AS_qvtp_qvtcas {
*
- */
- protected boolean MAP_m_Root_RootCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS lRootCS_0) {
- try {
- // predicates and unrealized variables
- // creations
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Root rRoot = MiniOCLFactory.eINSTANCE.createRoot();
- assert rRoot != null;
- models[1/*rightAS*/].add(rRoot);
- // property assignments
- lRootCS_0.setAst(rRoot);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Root_RootCS = ValueUtil.TRUE_VALUE;
- return m_Root_RootCS;
- } catch (Throwable e) {
- return handleExecutionFailure("MAP_m_Root_RootCS", e);
- }
- }
-
- /**
- *
- * map m_String_ParameterCS in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lParameterCS : minioclcs::ParameterCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {aParameter : miniocl::Parameter[1];
- * ast : miniocl::Element[1];
- * |}
- * where ( |)
- * {name : ecore::EString[?];
- * toString : String[1];
- * |
- * aParameter := lParameterCS.ast;
- * ast := lParameterCS.ast;
- * name := lParameterCS.name;
- * toString := name.toString();
- * aParameter.name := toString;
- * }
+ * guard:leftCS lRootCS : minioclcs::RootCS[1];
+ * var ast : miniocl::Element[1] := lRootCS.ast;
+ * var packages : OrderedSet(minioclcs::PackageCS)[*|1] := lRootCS.packages;
+ * var aRoot : miniocl::Root[1] := ast.oclAsType(miniocl::Root)
+ * ;
+ * var _'\u00ABcollect\u00BB' : Sequence(miniocl::Package)[*|1] := packages->collect(_'1_' |
+ * _'1_'.ast.oclAsType(miniocl::Package))
+ * ;
+ * var asOrderedSet : OrderedSet(miniocl::Package)[*|1] := _'\u00ABcollect\u00BB'->asOrderedSet();
+ * set aRoot.ownedPackages := asOrderedSet;
*
*/
- protected boolean MAP_m_String_ParameterCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull ParameterCS lParameterCS_1) {
+ protected boolean MAP_m_RootCS_ast_packages(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS lRootCS) {
try {
- // predicates and unrealized variables
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lParameterCS_1.getAst();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lRootCS.getAst();
final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aParameter;
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof Parameter;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_5;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Parameter symbol_2 = (Parameter)ast;
- if (symbol_2 == null) {
- throw throwNull(lParameterCS_1, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lParameterCS_1, "Null where non-null value required");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lParameterCS_1.getName();
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
- // property assignments
- symbol_2.setName(toString);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_String_ParameterCS = ValueUtil.TRUE_VALUE;
- raw_ast = m_String_ParameterCS;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
- }
- symbol_5 = raw_ast;
+ if (ast == null) {
+ throw throwNull(lRootCS, "Null where non-null value required");
}
- else {
- symbol_5 = ValueUtil.FALSE_VALUE;
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PackageCS> packages = lRootCS.getPackages();
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Root_0 = idResolver.getClass(CLSSid_Root, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Root oclAsType = ClassUtil.nonNullState((Root)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast, TYP_miniocl_c_c_Root_0));
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_packages = idResolver.createOrderedSetOfAll(ORD_CLSSid_PackageCS, packages);
+ /*@Thrown*/ SequenceValue.@org.eclipse.jdt.annotation.NonNull Accumulator accumulator = ValueUtil.createSequenceAccumulatorValue(SEQ_CLSSid_Package);
+ @NonNull Iterator<Object> ITERATOR__1 = BOXED_packages.iterator();
+ /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull SequenceValue collect;
+ while (true) {
+ if (!ITERATOR__1.hasNext()) {
+ collect = accumulator;
+ break;
+ }
+ @SuppressWarnings("null")
+ /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PackageCS _1 = (PackageCS)ITERATOR__1.next();
+ /**
+ * _'1_'.ast.oclAsType(miniocl::Package)
+ */
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_miniocl_c_c_Package_0 = idResolver.getClass(CLSSid_Package, null);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast_0 = _1.getAst();
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.NonNull Package oclAsType_0 = ClassUtil.nonNullState((Package)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, ast_0, TYP_miniocl_c_c_Package_0));
+ //
+ accumulator.add(oclAsType_0);
}
- raw_aParameter = symbol_5;
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue asOrderedSet = CollectionAsOrderedSetOperation.INSTANCE.evaluate(collect);
+ // mapping statements
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<Package> ECORE_asOrderedSet = ((IdResolver.IdResolverExtension)idResolver).ecoreValueOfAll(Package.class, asOrderedSet);
+ oclAsType.getOwnedPackages().addAll(ECORE_asOrderedSet);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_RootCS_ast_packages = ValueUtil.TRUE_VALUE;
+ raw_ast = m_RootCS_ast_packages;
}
else {
- raw_aParameter = ValueUtil.FALSE_VALUE;
+ raw_ast = ValueUtil.FALSE_VALUE;
}
- return raw_aParameter;
+ return raw_ast;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_String_ParameterCS", e);
+ return handleExecutionFailure("MAP_m_RootCS_ast_packages", e);
}
}
/**
*
- * map m_String_PropertyCS in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lPropertyCS : minioclcs::PropertyCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {aProperty : miniocl::Property[1];
- * ast : miniocl::Element[1];
- * |}
- * where ( |)
- * {name : ecore::EString[?];
- * toString : String[1];
- * |
- * aProperty := lPropertyCS.ast;
- * ast := lPropertyCS.ast;
- * name := lPropertyCS.name;
- * toString := name.toString();
- * aProperty.name := toString;
- * }
+ * map m_Root_RootCS in MiniOCLCS2AS_qvtp_qvtcas {
+ * guard:leftCS lRootCS : minioclcs::RootCS[1];
+ * new:rightAS rRoot : miniocl::Root[1];
+ * set lRootCS.ast := rRoot;
*
*/
- protected boolean MAP_m_String_PropertyCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull PropertyCS lPropertyCS_1) {
+ protected boolean MAP_m_Root_RootCS(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull RootCS lRootCS_0) {
try {
- // predicates and unrealized variables
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element ast = lPropertyCS_1.getAst();
- final /*@Thrown*/ boolean symbol_0 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_aProperty;
- if (symbol_0) {
- final /*@NonInvalid*/ boolean symbol_1 = ast instanceof org.eclipse.qvtd.doc.miniocl.Property;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_5;
- if (symbol_1) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Property symbol_2 = (org.eclipse.qvtd.doc.miniocl.Property)ast;
- if (symbol_2 == null) {
- throw throwNull(lPropertyCS_1, "Null where non-null value required");
- }
- final /*@Thrown*/ boolean symbol_3 = ast != null;
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean raw_ast;
- if (symbol_3) {
- if (ast == null) {
- throw throwNull(lPropertyCS_1, "Null where non-null value required");
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String name = lPropertyCS_1.getName();
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.NonNull String toString = OclAnyToStringOperation.INSTANCE.evaluate(name);
- // property assignments
- symbol_2.setName(toString);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_String_PropertyCS = ValueUtil.TRUE_VALUE;
- raw_ast = m_String_PropertyCS;
- }
- else {
- raw_ast = ValueUtil.FALSE_VALUE;
- }
- symbol_5 = raw_ast;
- }
- else {
- symbol_5 = ValueUtil.FALSE_VALUE;
- }
- raw_aProperty = symbol_5;
- }
- else {
- raw_aProperty = ValueUtil.FALSE_VALUE;
- }
- return raw_aProperty;
+ // creations
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Root rRoot = MiniOCLFactory.eINSTANCE.createRoot();
+ assert rRoot != null;
+ models[1/*rightAS*/].add(rRoot);
+ // mapping statements
+ lRootCS_0.setAst(rRoot);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_Root_RootCS = ValueUtil.TRUE_VALUE;
+ return m_Root_RootCS;
} catch (Throwable e) {
- return handleExecutionFailure("MAP_m_String_PropertyCS", e);
+ return handleExecutionFailure("MAP_m_Root_RootCS", e);
}
}
/**
*
- * map m_VariableExp_NameExpCS_CallExpCS_Element_Expressi in MiniOCLCS2AS_qvtp_qvtcas {
- * leftCS (lNameExpCS : minioclcs::NameExpCS[1];
- * |)
- * { |}
- * rightAS ( |)
- * {realize rVariableExp : miniocl::VariableExp[1];
- * |}
- * where ( |
- * not lNameExpCS.isPropCallExpWithExplicitSource()
- * lNameExpCS.isVariableExp())
- * { |
- * lNameExpCS.ast := rVariableExp;
- * }
+ * map m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen in MiniOCLCS2AS_qvtp_qvtcas {
+ *
+ * guard:leftCS lNameExpCS : minioclcs::NameExpCS[1];
+ * check lNameExpCS.isVariableExp()
+ * ;
+ * check not lNameExpCS.isPropCallExpWithExplicitSource();
+ * new:rightAS rVariableExp : miniocl::VariableExp[1];
+ * notify set lNameExpCS.ast := rVariableExp;
*
*/
- protected class MAP_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi extends AbstractInvocation
- {
- protected final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_9;
-
- public MAP_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi(@NonNull Object @NonNull [] boundValues) {
- lNameExpCS_9 = (NameExpCS)boundValues[0];
- }
-
- public boolean execute() {
+ protected boolean MAP_m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen(final /*@NonInvalid*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull NameExpCS lNameExpCS_9) {
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
+ /*@Caught*/ @Nullable Object CAUGHT_and_0;
try {
- // predicates and unrealized variables
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.ids.@org.eclipse.jdt.annotation.NonNull IdResolver idResolver = executor.getIdResolver();
- /*@Caught*/ @NonNull Object CAUGHT_eq;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_9.getRoundedBrackets();
- final /*@Thrown*/ boolean eq = roundedBrackets == null;
- CAUGHT_eq = eq;
- }
- catch (Exception e) {
- CAUGHT_eq = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
+ /*@Caught*/ @Nullable Object CAUGHT_and;
try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_9);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
- if (oclIsKindOf) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
- symbol_0 = oclAsType;
- }
- else {
- symbol_0 = null;
- }
- final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
- /*@Thrown*/ boolean symbol_1;
- if (eq_0) {
- symbol_1 = ValueUtil.FALSE_VALUE;
+ /*@Caught*/ @NonNull Object CAUGHT_eq;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets = lNameExpCS_9.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq = roundedBrackets == null;
+ CAUGHT_eq = eq;
}
- else {
- if (symbol_0 == null) {
- throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp = symbol_0.getNameExp();
- final /*@Thrown*/ boolean eq_1 = lNameExpCS_9.equals(nameExp);
- symbol_1 = eq_1;
+ catch (Exception e) {
+ CAUGHT_eq = ValueUtil.createInvalidValue(e);
}
- CAUGHT_symbol_1 = symbol_1;
- }
- catch (Exception e) {
- CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_symbol_1);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(and);
- if (not == null) {
- throw throwNull(lNameExpCS_9, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_6;
- if (not) {
- /*@Caught*/ @Nullable Object CAUGHT_and_1;
+ /*@Caught*/ @Nullable Object CAUGHT_not;
try {
- /*@Caught*/ @Nullable Object CAUGHT_and_0;
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_1;
try {
- /*@Caught*/ @NonNull Object CAUGHT_eq_2;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_9.getRoundedBrackets();
- final /*@Thrown*/ boolean eq_2 = roundedBrackets_0 == null;
- CAUGHT_eq_2 = eq_2;
- }
- catch (Exception e) {
- CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_9);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_2 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_0;
+ if (oclIsKindOf) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container, TYP_minioclcs_c_c_CallExpCS_2));
+ symbol_0 = oclAsType;
}
- /*@Caught*/ @Nullable Object CAUGHT_not_0;
- try {
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_9);
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
- final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
- /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
- if (oclIsKindOf_0) {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_0 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
- symbol_2 = oclAsType_0;
- }
- else {
- symbol_2 = null;
- }
- final /*@Thrown*/ boolean eq_3 = symbol_2 == null;
- /*@Thrown*/ boolean symbol_3;
- if (eq_3) {
- symbol_3 = ValueUtil.FALSE_VALUE;
- }
- else {
- if (symbol_2 == null) {
- throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::nameExp\'");
- }
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NameExpCS nameExp_0 = symbol_2.getNameExp();
- final /*@Thrown*/ boolean eq_4 = lNameExpCS_9.equals(nameExp_0);
- symbol_3 = eq_4;
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(symbol_3);
- CAUGHT_not_0 = not_0;
+ else {
+ symbol_0 = null;
}
- catch (Exception e) {
- CAUGHT_not_0 = ValueUtil.createInvalidValue(e);
+ final /*@Thrown*/ boolean eq_0 = symbol_0 == null;
+ /*@Thrown*/ boolean symbol_1;
+ if (eq_0) {
+ symbol_1 = ValueUtil.FALSE_VALUE;
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_2, CAUGHT_not_0);
- CAUGHT_and_0 = and_0;
- }
- catch (Exception e) {
- CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
- }
- /*@Caught*/ @NonNull Object CAUGHT_eq_5;
- try {
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_9.getExpName();
- if (expName == null) {
- throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ else {
+ if (symbol_0 == null) {
+ throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp = symbol_0.getNavExp();
+ final /*@Thrown*/ boolean eq_1 = lNameExpCS_9.equals(navExp);
+ symbol_1 = eq_1;
}
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path = expName.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path);
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_path);
- final /*@Thrown*/ boolean eq_5 = size.equals(INT_1);
- CAUGHT_eq_5 = eq_5;
+ CAUGHT_symbol_1 = symbol_1;
}
catch (Exception e) {
- CAUGHT_eq_5 = ValueUtil.createInvalidValue(e);
+ CAUGHT_symbol_1 = ValueUtil.createInvalidValue(e);
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_eq_5);
- CAUGHT_and_1 = and_1;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_symbol_1);
+ CAUGHT_not = not;
}
catch (Exception e) {
- CAUGHT_and_1 = ValueUtil.createInvalidValue(e);
+ CAUGHT_not = ValueUtil.createInvalidValue(e);
}
- /*@Caught*/ @NonNull Object CAUGHT_ne;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq, CAUGHT_not);
+ CAUGHT_and = and;
+ }
+ catch (Exception e) {
+ CAUGHT_and = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_eq_2;
+ try {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName = lNameExpCS_9.getExpName();
+ if (expName == null) {
+ throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements = expName.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements);
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull IntegerValue size = CollectionSizeOperation.INSTANCE.evaluate(BOXED_pathElements);
+ final /*@Thrown*/ boolean eq_2 = size.equals(INT_1);
+ CAUGHT_eq_2 = eq_2;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_0 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and, CAUGHT_eq_2);
+ CAUGHT_and_0 = and_0;
+ }
+ catch (Exception e) {
+ CAUGHT_and_0 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_ne;
+ try {
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_9);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_0 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_0.getAst();
+ if (self_1 == null) {
+ throw throwNull(lNameExpCS_9, "Null where non-null value required");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_9.getExpName();
+ if (expName_0 == null) {
+ throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::pathElements\'");
+ }
+ @SuppressWarnings("null")
+ final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> pathElements_0 = expName_0.getPathElements();
+ final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_pathElements_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, pathElements_0);
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_pathElements_0);
+ if (aPathElementCS == null) {
+ throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
+ MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
+ Variable _lookupUnqualifiedVariable = null;
+ if (_lookupResult.size() == 1) {
+ _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
+ } else {
+ handleLookupError(aPathElementCS,elementName);
+ };
+ final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
+ CAUGHT_ne = ne;
+ }
+ catch (Exception e) {
+ CAUGHT_ne = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_1 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_0, CAUGHT_ne);
+ if (and_1 == null) {
+ throw throwNull(lNameExpCS_9, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_7;
+ if (and_1) {
+ /*@Caught*/ @Nullable Object CAUGHT_and_2;
+ try {
+ /*@Caught*/ @NonNull Object CAUGHT_eq_3;
try {
- final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CSTrace_0 = idResolver.getClass(CLSSid_CSTrace, null);
- final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object oclContainer = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_9);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CSTrace oclAsType_1 = ClassUtil.nonNullState((CSTrace)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, oclContainer, TYP_minioclcs_c_c_CSTrace_0));
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable Element self_1 = oclAsType_1.getAst();
- if (self_1 == null) {
- throw throwNull(lNameExpCS_9, "Null where non-null value required");
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable RoundedBracketClauseCS roundedBrackets_0 = lNameExpCS_9.getRoundedBrackets();
+ final /*@Thrown*/ boolean eq_3 = roundedBrackets_0 == null;
+ CAUGHT_eq_3 = eq_3;
+ }
+ catch (Exception e) {
+ CAUGHT_eq_3 = ValueUtil.createInvalidValue(e);
+ }
+ /*@Caught*/ @NonNull Object CAUGHT_symbol_3;
+ try {
+ final /*@NonInvalid*/ java.lang.@org.eclipse.jdt.annotation.Nullable Object container_0 = ClassifierOclContainerOperation.INSTANCE.evaluate(executor, lNameExpCS_9);
+ final /*@NonInvalid*/ org.eclipse.ocl.pivot.@org.eclipse.jdt.annotation.NonNull Class TYP_minioclcs_c_c_CallExpCS_4 = idResolver.getClass(CLSSid_CallExpCS, null);
+ final /*@Thrown*/ boolean oclIsKindOf_0 = OclAnyOclIsKindOfOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4).booleanValue();
+ /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable CallExpCS symbol_2;
+ if (oclIsKindOf_0) {
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.NonNull CallExpCS oclAsType_1 = ClassUtil.nonNullState((CallExpCS)OclAnyOclAsTypeOperation.INSTANCE.evaluate(executor, container_0, TYP_minioclcs_c_c_CallExpCS_4));
+ symbol_2 = oclAsType_1;
}
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathNameCS expName_0 = lNameExpCS_9.getExpName();
- if (expName_0 == null) {
- throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathNameCS::path\'");
+ else {
+ symbol_2 = null;
}
- @SuppressWarnings("null")
- final /*@Thrown*/ java.util.@org.eclipse.jdt.annotation.NonNull List<PathElementCS> path_0 = expName_0.getPath();
- final /*@Thrown*/ org.eclipse.ocl.pivot.values.@org.eclipse.jdt.annotation.NonNull OrderedSetValue BOXED_path_0 = idResolver.createOrderedSetOfAll(ORD_CLSSid_PathElementCS, path_0);
- final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable PathElementCS aPathElementCS = (PathElementCS)OrderedCollectionFirstOperation.INSTANCE.evaluate(BOXED_path_0);
- if (aPathElementCS == null) {
- throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::PathElementCS::elementName\'");
+ final /*@Thrown*/ boolean eq_4 = symbol_2 == null;
+ /*@Thrown*/ boolean symbol_3;
+ if (eq_4) {
+ symbol_3 = ValueUtil.FALSE_VALUE;
}
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable String elementName = aPathElementCS.getElementName();
- MiniOCLLookupResult<Variable> _lookupResult = lookupSolver._lookupUnqualifiedVariable(self_1, (String)elementName);
- Variable _lookupUnqualifiedVariable = null;
- if (_lookupResult.size() == 1) {
- _lookupUnqualifiedVariable = _lookupResult.getSingleResult();
- } else {
- handleLookupError(aPathElementCS,elementName);
- };
- final /*@Thrown*/ boolean ne = _lookupUnqualifiedVariable != null;
- CAUGHT_ne = ne;
+ else {
+ if (symbol_2 == null) {
+ throw throwNull(lNameExpCS_9, "Null source for \'\'http://www.eclipse.org/qvtd/doc/MiniOCLCS\'::CallExpCS::navExp\'");
+ }
+ final /*@Thrown*/ org.eclipse.qvtd.doc.minioclcs.@org.eclipse.jdt.annotation.Nullable NavigationExpCS navExp_0 = symbol_2.getNavExp();
+ final /*@Thrown*/ boolean eq_5 = lNameExpCS_9.equals(navExp_0);
+ symbol_3 = eq_5;
+ }
+ CAUGHT_symbol_3 = symbol_3;
}
catch (Exception e) {
- CAUGHT_ne = ValueUtil.createInvalidValue(e);
- }
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_and_1, CAUGHT_ne);
- if (and_2 == null) {
- throw throwNull(lNameExpCS_9, "Null if condition");
- }
- /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_5;
- if (and_2) {
- // creations
- final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable VariableExp rVariableExp = MiniOCLFactory.eINSTANCE.createVariableExp();
- assert rVariableExp != null;
- models[1/*rightAS*/].add(rVariableExp);
- // property assignments
- lNameExpCS_9.setAst(rVariableExp);
- objectManager.assigned(lNameExpCS_9, MinioclcsPackage.Literals.CS_TRACE__AST, rVariableExp, null);
- final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_VariableExp_NameExpCS_CallExpCS_Element_Expressi = ValueUtil.TRUE_VALUE;
- symbol_5 = m_VariableExp_NameExpCS_CallExpCS_Element_Expressi;
- }
- else {
- symbol_5 = ValueUtil.FALSE_VALUE;
+ CAUGHT_symbol_3 = ValueUtil.createInvalidValue(e);
}
- symbol_6 = symbol_5;
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean and_2 = BooleanAndOperation.INSTANCE.evaluate(CAUGHT_eq_3, CAUGHT_symbol_3);
+ CAUGHT_and_2 = and_2;
+ }
+ catch (Exception e) {
+ CAUGHT_and_2 = ValueUtil.createInvalidValue(e);
+ }
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean not_0 = BooleanNotOperation.INSTANCE.evaluate(CAUGHT_and_2);
+ if (not_0 == null) {
+ throw throwNull(lNameExpCS_9, "Null if condition");
+ }
+ /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean symbol_6;
+ if (not_0) {
+ // creations
+ final /*@Thrown*/ org.eclipse.qvtd.doc.miniocl.@org.eclipse.jdt.annotation.Nullable VariableExp rVariableExp = MiniOCLFactory.eINSTANCE.createVariableExp();
+ assert rVariableExp != null;
+ models[1/*rightAS*/].add(rVariableExp);
+ // mapping statements
+ lNameExpCS_9.setAst(rVariableExp);
+ objectManager.assigned(lNameExpCS_9, MinioclcsPackage.Literals.CS_TRACE__AST, rVariableExp, null);
+ final /*@Thrown*/ java.lang.@org.eclipse.jdt.annotation.Nullable Boolean m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen = ValueUtil.TRUE_VALUE;
+ symbol_6 = m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen;
}
else {
symbol_6 = ValueUtil.FALSE_VALUE;
}
- return symbol_6;
- } catch (Throwable e) {
- return handleExecutionFailure("MAP_m_VariableExp_NameExpCS_CallExpCS_Element_Expressi", e);
+ symbol_7 = symbol_6;
}
- }
-
- public boolean isEqual(@NonNull IdResolver idResolver, @NonNull Object @NonNull [] thoseValues) {
- return idResolver.oclEquals(lNameExpCS_9, thoseValues[0]);
+ else {
+ symbol_7 = ValueUtil.FALSE_VALUE;
+ }
+ return symbol_7;
+ } catch (Throwable e) {
+ return handleExecutionFailure("MAP_m_VariableExp_NameExpCS_CallExpCS_CallExpCS_Elemen", e);
}
}
}
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractComputationConstructor.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractComputationConstructor.java
index 1342e9751..795d4578a 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractComputationConstructor.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractComputationConstructor.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -32,7 +32,7 @@ import org.eclipse.qvtd.doc.minioclcs.xtext.tx.Computation;
public abstract class AbstractComputationConstructor implements Computation.Constructor
{
protected final IdResolver.@NonNull IdResolverExtension idResolver;
-
+
/**
* Map from invocation hashCode to one or more computations with that hashCode. Single map entries use the
* Computation directly as the entry. Colliding entries use a List<@NonNull Computation> for the collisions.
@@ -40,72 +40,84 @@ public abstract class AbstractComputationConstructor implements Computation.Cons
* This map is used to inhibit repeated computations.
*/
private final @NonNull Map<@NonNull Integer, @NonNull Object> hashCode2computations = new HashMap<@NonNull Integer, @NonNull Object>();
-
+
+ protected final boolean debugInvocations = AbstractTransformer.INVOCATIONS.isActive();
+
protected AbstractComputationConstructor(@NonNull IdResolver idResolver) {
this.idResolver = (IdResolver.IdResolverExtension)idResolver;
}
-
+
@Override
public @NonNull Computation getUniqueComputation(@Nullable Object @NonNull ... argValues) {
int hashCode = 0;
- for (@Nullable Object argValue : argValues) {
- hashCode = 3 * hashCode + idResolver.oclHashCode(argValue);
- }
- synchronized (hashCode2computations) {
- Object zeroOrMoreComputations = hashCode2computations.get(hashCode);
- Computation oneComputation = null;
- if (zeroOrMoreComputations instanceof Computation) {
- oneComputation = (Computation)zeroOrMoreComputations;
- if (oneComputation.isEqual(idResolver, argValues)) {
- AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + oneComputation);
- return oneComputation;
- }
- }
- else if (zeroOrMoreComputations instanceof List<?>) {
- @SuppressWarnings("unchecked")@NonNull List<@NonNull Computation> zeroOrMoreComputations2 = (List<@NonNull Computation>)zeroOrMoreComputations;
+ for (@Nullable Object argValue : argValues) {
+ hashCode = 3 * hashCode + idResolver.oclHashCode(argValue);
+ }
+ synchronized (hashCode2computations) {
+ Object zeroOrMoreComputations = hashCode2computations.get(hashCode);
+ Computation oneComputation = null;
+ if (zeroOrMoreComputations instanceof Computation) {
+ oneComputation = (Computation)zeroOrMoreComputations;
+ if (oneComputation.isEqual(idResolver, argValues)) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + oneComputation);
+ }
+ return oneComputation;
+ }
+ }
+ else if (zeroOrMoreComputations instanceof List<?>) {
+ @SuppressWarnings("unchecked")@NonNull List<@NonNull Computation> zeroOrMoreComputations2 = (List<@NonNull Computation>)zeroOrMoreComputations;
for (@NonNull Computation aComputation : zeroOrMoreComputations2) {
- if (aComputation.isEqual(idResolver, argValues)) {
- AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + aComputation);
- return aComputation;
- }
- }
- }
- }
- //
- // Must resynchronize after newInstance creation and execution in case the execution is recursive.
- //
- Computation theComputation = newInstance(argValues);
- synchronized (hashCode2computations) {
- Object zeroOrMoreComputations = hashCode2computations.get(hashCode);
+ if (aComputation.isEqual(idResolver, argValues)) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + aComputation);
+ }
+ return aComputation;
+ }
+ }
+ }
+ }
+ //
+ // Must resynchronize after newInstance creation and execution in case the execution is recursive.
+ //
+ Computation theComputation = newInstance(argValues);
+ synchronized (hashCode2computations) {
+ Object zeroOrMoreComputations = hashCode2computations.get(hashCode);
if (zeroOrMoreComputations == null) {
hashCode2computations.put(hashCode, theComputation);
}
else if (zeroOrMoreComputations instanceof Computation) {
Computation oneComputation = (Computation)zeroOrMoreComputations;
- if (oneComputation.isEqual(idResolver, argValues)) {
- AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + oneComputation);
- return oneComputation;
- }
- List<@NonNull Computation> twoOrMoreComputations = new ArrayList<@NonNull Computation>(4);
- twoOrMoreComputations.add(oneComputation);
- twoOrMoreComputations.add(theComputation);
- hashCode2computations.put(hashCode, twoOrMoreComputations);
+ if (oneComputation.isEqual(idResolver, argValues)) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + oneComputation);
+ }
+ return oneComputation;
+ }
+ List<@NonNull Computation> twoOrMoreComputations = new ArrayList<@NonNull Computation>(4);
+ twoOrMoreComputations.add(oneComputation);
+ twoOrMoreComputations.add(theComputation);
+ hashCode2computations.put(hashCode, twoOrMoreComputations);
+ }
+ else if (zeroOrMoreComputations instanceof List<?>) {
+ @SuppressWarnings("unchecked")@NonNull List<@NonNull Computation> twoOrMoreComputations = (List<@NonNull Computation>)zeroOrMoreComputations;
+ for (@NonNull Computation aComputation : twoOrMoreComputations) {
+ if (aComputation.isEqual(idResolver, argValues)) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + aComputation);
+ }
+ return aComputation;
+ }
+ }
+ twoOrMoreComputations.add(theComputation);
+ }
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("getUniqueComputation new:" + theComputation);
}
- else if (zeroOrMoreComputations instanceof List<?>) {
- @SuppressWarnings("unchecked")@NonNull List<@NonNull Computation> twoOrMoreComputations = (List<@NonNull Computation>)zeroOrMoreComputations;
- for (@NonNull Computation aComputation : twoOrMoreComputations) {
- if (aComputation.isEqual(idResolver, argValues)) {
- AbstractTransformer.INVOCATIONS.println("getUniqueComputation old:" + aComputation);
- return aComputation;
- }
- }
- twoOrMoreComputations.add(theComputation);
- }
- AbstractTransformer.INVOCATIONS.println("getUniqueComputation new:" + theComputation);
return theComputation;
- }
- }
+ }
+ }
protected abstract @NonNull Computation newInstance(@Nullable Object @NonNull [] values);
-
+
} \ No newline at end of file
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractTransformerInternal.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractTransformerInternal.java
index fef142178..d4496e2db 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractTransformerInternal.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/AbstractTransformerInternal.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -24,6 +24,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
+import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -40,14 +41,18 @@ import org.eclipse.ocl.pivot.evaluation.AbstractModelManager;
import org.eclipse.ocl.pivot.evaluation.Evaluator;
import org.eclipse.ocl.pivot.evaluation.Executor;
import org.eclipse.ocl.pivot.ids.ClassId;
+import org.eclipse.ocl.pivot.ids.CollectionTypeId;
import org.eclipse.ocl.pivot.ids.IdManager;
import org.eclipse.ocl.pivot.ids.IdResolver;
import org.eclipse.ocl.pivot.ids.PackageId;
import org.eclipse.ocl.pivot.ids.PropertyId;
import org.eclipse.ocl.pivot.ids.TypeId;
+import org.eclipse.ocl.pivot.internal.evaluation.EvaluationCache;
+import org.eclipse.ocl.pivot.internal.values.SetValueImpl;
import org.eclipse.ocl.pivot.utilities.ClassUtil;
import org.eclipse.ocl.pivot.utilities.NameUtil;
import org.eclipse.ocl.pivot.values.InvalidValueException;
+import org.eclipse.ocl.pivot.values.SetValue;
import org.eclipse.qvtd.doc.minioclcs.xtext.tx.AbstractTransformer;
import org.eclipse.qvtd.doc.minioclcs.xtext.tx.AbstractTypedModelInstance;
import org.eclipse.qvtd.doc.minioclcs.xtext.tx.ExecutionVisitable;
@@ -60,42 +65,42 @@ import org.eclipse.qvtd.doc.minioclcs.xtext.tx.Transformer;
/**
* The abstract implementation of an auto-generated transformation provides the shared infrastructure for maintaining
* models and deferring invocation of not-ready mapping invocations.
- *
+ *
* at-since 1.1
*/
public abstract class AbstractTransformerInternal extends AbstractModelManager implements Transformer, ExecutionVisitable
-{
+{
private static final @NonNull List<@NonNull Integer> EMPTY_INDEX_LIST = Collections.emptyList();
private static final @NonNull List<@NonNull Object> EMPTY_EOBJECT_LIST = Collections.emptyList();
-
+
protected class Model extends AbstractTypedModelInstance
{
protected final @NonNull String name;
- private @Nullable Set<@NonNull Object> allEObjects = null;
+ private @Nullable List<@NonNull Object> allEObjects = null;
private @Nullable List<@NonNull Object> rootEObjects = null;
private @Nullable Map<@NonNull EClass, @NonNull Set<@NonNull Integer>> eClass2allClassIndexes = null;
/**
* All possible allInstances() returns indexed by the ClassIndex of the ClassId for which allInstances() may be invoked.
*/
- private final @NonNull Set<@NonNull Object>[] classIndex2objects;
-
+ private final @NonNull List<@NonNull Object> @Nullable [] classIndex2objects;
+
public Model(@NonNull String name, @NonNull PropertyId @Nullable [] propertyIndex2propertyId, @NonNull ClassId @Nullable [] classIndex2classId, int @Nullable [] @NonNull [] classIndex2allClassIndexes) {
this.name = name;
//
// Prepare the allInstances() fields
//
if (classIndex2classId != null) {
- assert classIndex2allClassIndexes != null;
- int classIds = classIndex2classId.length;
- @SuppressWarnings("unchecked")@NonNull Set<Object> @NonNull [] classIndex2objects = (@NonNull Set<Object> @NonNull []) new @NonNull HashSet<?> @NonNull [classIds];
+ assert classIndex2allClassIndexes != null;
+ int classIds = classIndex2classId.length;
+ @SuppressWarnings("unchecked")@NonNull List<@NonNull Object> @NonNull [] classIndex2objects = (@NonNull List<@NonNull Object> @NonNull []) new @NonNull ArrayList<?> @NonNull [classIds];
this.classIndex2objects = classIndex2objects;
- for (int i = 0; i < classIds; i++) {
- classIndex2objects[i] = new HashSet<Object>();
- }
+ for (int i = 0; i < classIds; i++) {
+ classIndex2objects[i] = new ArrayList<>();
+ }
}
else {
- this.classIndex2objects = null;
+ this.classIndex2objects = null;
}
}
@@ -108,9 +113,9 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
* If eClass2allPropertyIndexes is non-null, eObject is added to the unnavigable opposites caches potentially updating eClass2allPropertyIndexes with
* the state of a new EClass.
*/
- private void accumulateEObject(@Nullable Map<@NonNull EClass, @NonNull Set<@NonNull Integer>> eClass2allClassIndexes,
- @Nullable Map<@NonNull EClass, @NonNull List<@NonNull Integer>> eClass2allPropertyIndexes, @Nullable Map<@NonNull EReference, @NonNull Integer> eReference2propertyIndex,
- @NonNull Object eObject) {
+ private void accumulateEObject(@Nullable Map<@NonNull EClass, @NonNull Set<@NonNull Integer>> eClass2allClassIndexes,
+ @Nullable Map<@NonNull EClass, @NonNull List<@NonNull Integer>> eClass2allPropertyIndexes, @Nullable Map<@NonNull EReference, @NonNull Integer> eReference2propertyIndex,
+ @NonNull Object eObject) {
EClass eClass = eClass(eObject);
if (eClass2allClassIndexes != null) {
Set<@NonNull Integer> allClassIndexes = eClass2allClassIndexes.get(eClass);
@@ -118,7 +123,7 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
allClassIndexes = getClassIndexes(eClass);
eClass2allClassIndexes.put(eClass, allClassIndexes);
}
- Set<@NonNull Object>[] classIndex2objects2 = classIndex2objects;
+ List<@NonNull Object>[] classIndex2objects2 = classIndex2objects;
assert classIndex2objects2 != null;
for (@NonNull Integer classIndex : allClassIndexes) {
classIndex2objects2[classIndex].add(eObject);
@@ -151,36 +156,37 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
}
public void add(@NonNull EObject eObject) {
- Set<@NonNull Object> allEObjects2 = allEObjects;
+ List<@NonNull Object> allEObjects2 = allEObjects;
if (allEObjects2 == null) {
- allEObjects = allEObjects2 = new HashSet<@NonNull Object>();
+ allEObjects = allEObjects2 = new ArrayList<>();
}
rootEObjects = null;
+ assert !allEObjects2.contains(eObject);
allEObjects2.add(eObject);
if ((eClass2allClassIndexes == null) && (classId2classIndexes != null) && (classIndex2objects != null)) {
- eClass2allClassIndexes = new HashMap<@NonNull EClass, @NonNull Set<@NonNull Integer>>();
+ eClass2allClassIndexes = new HashMap<>();
}
accumulateEObject(eClass2allClassIndexes, null, null, eObject);
}
-
+
/**
- * Add eRootObjects to the modelIndex model.
- */
+ * Add eRootObjects to the modelIndex model.
+ */
public void addRootObjects(@NonNull Iterable<@NonNull ? extends Object> eRootObjects) {
List<@NonNull Object> rootEObjects2 = rootEObjects;
if (rootEObjects2 == null) {
- rootEObjects = rootEObjects2 = new ArrayList<@NonNull Object>();
+ rootEObjects = rootEObjects2 = new ArrayList<>();
}
allEObjects = null;
- Map<@NonNull EClass, @NonNull Set<@NonNull Integer>> eClass2allClassIndexes = null;
+ Map<@NonNull EClass, @NonNull Set<@NonNull Integer>> eClass2allClassIndexes = null;
Map<@NonNull EClass, @NonNull List<@NonNull Integer>> eClass2allPropertyIndexes = null;
Map<@NonNull EReference, @NonNull Integer> eReference2propertyIndex = null;
if ((classId2classIndexes != null) && (classIndex2objects != null)) {
- eClass2allClassIndexes = new HashMap<@NonNull EClass, @NonNull Set<@NonNull Integer>>();
+ eClass2allClassIndexes = new HashMap<>();
}
if (propertyIndex2propertyId != null) {
- eClass2allPropertyIndexes = new HashMap<@NonNull EClass, @NonNull List<@NonNull Integer>>();
- eReference2propertyIndex = new HashMap<@NonNull EReference, @NonNull Integer>();
+ eClass2allPropertyIndexes = new HashMap<>();
+ eReference2propertyIndex = new HashMap<>();
}
for (Object eRootObject : eRootObjects) {
//
@@ -201,22 +207,24 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
}
}
}
-
+
@Override
public @NonNull Collection<@NonNull Object> getAllObjects() {
- Set<@NonNull Object> allEObjects2 = allEObjects;
+ List<@NonNull Object> allEObjects2 = allEObjects;
if (allEObjects2 == null) {
- allEObjects = allEObjects2 = new HashSet<@NonNull Object>();
+ allEObjects = allEObjects2 = new ArrayList<>();
if (rootEObjects != null) {
- for (@NonNull Object eRootObject : rootEObjects) {
- allEObjects2.add(eRootObject);
- for (TreeIterator<? extends Object> tit = eAllContents(eRootObject); tit.hasNext(); ) {
- Object eObject = tit.next();
- if (eObject != null) {
- allEObjects2.add(eObject);
- }
- }
- }
+ for (@NonNull Object eRootObject : rootEObjects) {
+ assert !allEObjects2.contains(eRootObject);
+ allEObjects2.add(eRootObject);
+ for (TreeIterator<? extends Object> tit = eAllContents(eRootObject); tit.hasNext(); ) {
+ Object eObject = tit.next();
+ if (eObject != null) {
+ assert !allEObjects2.contains(eObject);
+ allEObjects2.add(eObject);
+ }
+ }
+ }
}
}
return allEObjects2;
@@ -229,9 +237,9 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
TypeId classId = type.getTypeId();
Integer classIndex = classId2classIndex2.get(classId);
if (classIndex != null) {
- Set<@NonNull Object>[] classIndex2objects2 = classIndex2objects;
+ List<@NonNull Object>[] classIndex2objects2 = classIndex2objects;
if (classIndex2objects2 != null) {
- Set<@NonNull Object> objects = classIndex2objects2[classIndex];
+ List<@NonNull Object> objects = classIndex2objects2[classIndex];
if (objects != null) {
return objects;
}
@@ -247,8 +255,8 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
}
/**
- * Return all objects in the modelIndex model that conform to eClass.
- *
+ * Return all objects in the modelIndex model that conform to eClass.
+ *
protected @NonNull <T extends EObject> List<T> getObjectsByType(@NonNull EClass eClass) {
List<T> selectedEObjects = new ArrayList<T>();
if (rootEObjects != null) {
@@ -273,13 +281,13 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
public @NonNull Collection<@NonNull Object> getRootObjects() {
List<@NonNull Object> rootEObjects2 = rootEObjects;
if (rootEObjects2 == null) {
- rootEObjects = rootEObjects2 = new ArrayList<@NonNull Object>();
+ rootEObjects = rootEObjects2 = new ArrayList<>();
if (allEObjects != null) {
- for (@NonNull Object eObject : allEObjects) {
- if (eContainer(eObject) == null) {
- rootEObjects2.add(eObject);
- }
- }
+ for (@NonNull Object eObject : allEObjects) {
+ if (eContainer(eObject) == null) {
+ rootEObjects2.add(eObject);
+ }
+ }
}
}
return rootEObjects2;
@@ -295,14 +303,115 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
return name;
}
}
-
+
+ private static class UnenforcedSetAccumulator extends SetValueImpl implements SetValue.Accumulator
+ {
+ public UnenforcedSetAccumulator(@NonNull CollectionTypeId typeId) {
+ super(typeId, new ArrayList<Object>());
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public boolean add(@Nullable Object value) {
+ assert !((Collection<Object>)elements).contains(value);
+ return ((Collection<Object>)elements).add(value);
+ }
+ }
+
+ private static class UnmodifiableCollectionAsSet<T> implements Set<T>
+ {
+ protected final @NonNull Collection<@NonNull T> collection;
+
+ private UnmodifiableCollectionAsSet(@NonNull Collection<@NonNull T> collection) {
+ this.collection = collection;
+ assert collection.size() == new HashSet<>(collection).size();
+ }
+
+ @Override
+ public boolean add(T e) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean addAll(@NonNull Collection<? extends T> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public void clear() {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean contains(Object o) {
+ return collection.contains(o);
+ }
+
+ @Override
+ public boolean containsAll(Collection<?> c) {
+ return collection.containsAll(c);
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ return collection.equals(obj);
+ }
+
+ @Override
+ public int hashCode() {
+ return collection.hashCode();
+ }
+
+ @Override
+ public boolean isEmpty() {
+ return collection.isEmpty();
+ }
+
+ @Override
+ public @NonNull Iterator<T> iterator() {
+ return collection.iterator();
+ }
+
+ @Override
+ public boolean remove(Object o) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean removeAll(Collection<?> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean retainAll(Collection<?> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public int size() {
+ return collection.size();
+ }
+
+ @Override
+ public Object[] toArray() {
+ return collection.toArray();
+ }
+
+ @Override
+ public <T1> T1[] toArray(T1[] a) {
+ return collection.toArray(a);
+ }
+ }
+
protected final @NonNull Executor executor;
/** deprecated use executor */
@Deprecated
protected final @NonNull Evaluator evaluator;
protected final IdResolver.@NonNull IdResolverExtension idResolver;
protected final @NonNull Model @NonNull [] models;
- protected final @NonNull Map<String, Integer> modelIndexes = new HashMap<String, Integer>();
+ protected final @NonNull Map<@NonNull String, @NonNull Integer> modelIndexes = new HashMap<>();
+ protected final boolean debugExceptions = AbstractTransformer.EXCEPTIONS.isActive();
+ protected final boolean debugInvocations = AbstractTransformer.INVOCATIONS.isActive();
/**
* Unchanging configured list PropertyId for which unnavigable opposite navigation may occur indexed by the PropertyIndex for that PropertyId.
@@ -346,7 +455,12 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
* Manager for the auxiliary object and property state.
*/
protected final @NonNull ObjectManager objectManager;
-
+
+ /**
+ * Cache of operation evaluations.
+ */
+ protected final @NonNull EvaluationCache evaluationCache;
+
protected AbstractTransformerInternal(@NonNull Executor executor, @NonNull String @NonNull [] modelNames,
@NonNull PropertyId @Nullable [] propertyIndex2propertyId, @NonNull ClassId @Nullable [] classIndex2classId, int @Nullable [] @NonNull [] classIndex2allClassIndexes) {
this.executor = executor;
@@ -354,6 +468,7 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
this.idResolver = (IdResolver.IdResolverExtension)executor.getIdResolver();
this.invocationManager = createInvocationManager();
this.objectManager = createObjectManager();
+ this.evaluationCache = createEvaluationCache();
this.models = new @NonNull Model @NonNull [modelNames.length];
for (int i = 0; i < modelNames.length; i++) {
String modelName = modelNames[i];
@@ -364,9 +479,9 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
// Prepare the unnavigable opposite property fields
//
if (propertyIndex2propertyId != null) {
- int propertyIds = propertyIndex2propertyId.length;
- this.propertyIndex2propertyId = propertyIndex2propertyId;
- HashMap<PropertyId, Integer> propertyId2propertyIndex2 = new HashMap<PropertyId, Integer>(propertyIds);
+ int propertyIds = propertyIndex2propertyId.length;
+ this.propertyIndex2propertyId = propertyIndex2propertyId;
+ Map<@NonNull PropertyId, @NonNull Integer> propertyId2propertyIndex2 = new HashMap<>(propertyIds);
this.propertyId2propertyIndex = propertyId2propertyIndex2;
this.propertyIndex2eReference = new @Nullable EReference @NonNull [propertyIds];
for (int propertyIndex = 0; propertyIndex < propertyIds; propertyIndex++) {
@@ -375,30 +490,30 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
}
@SuppressWarnings("unchecked")@NonNull Map<@NonNull Object, @NonNull Object> @Nullable [] object2oppositeObject = (@NonNull Map<@NonNull Object, @NonNull Object> @NonNull []) new HashMap<?,?> @NonNull [propertyIds];
this.object2oppositeObject = object2oppositeObject;
- for (int i = 0; i < propertyIds; i++) {
- object2oppositeObject[i] = new HashMap<@NonNull Object, @NonNull Object>();
- }
+ for (int i = 0; i < propertyIds; i++) {
+ object2oppositeObject[i] = new HashMap<>();
+ }
}
else {
- this.propertyIndex2propertyId = null;
- this.propertyId2propertyIndex = null;
- this.propertyIndex2eReference = null;
- this.object2oppositeObject = null;
+ this.propertyIndex2propertyId = null;
+ this.propertyId2propertyIndex = null;
+ this.propertyIndex2eReference = null;
+ this.object2oppositeObject = null;
}
//
// Prepare the allInstances() fields
//
if (classIndex2classId != null) {
- assert classIndex2allClassIndexes != null;
- int classIds = classIndex2classId.length;
- HashMap<@NonNull ClassId, @NonNull Integer> classId2classIndex2 = new HashMap<@NonNull ClassId, @NonNull Integer>(classIds);
- HashMap<@NonNull ClassId, @NonNull Set<@NonNull Integer>> classId2classIndexes2 = new HashMap<@NonNull ClassId, @NonNull Set<@NonNull Integer>>(classIds);
+ assert classIndex2allClassIndexes != null;
+ int classIds = classIndex2classId.length;
+ HashMap<@NonNull ClassId, @NonNull Integer> classId2classIndex2 = new HashMap<>(classIds);
+ HashMap<@NonNull ClassId, @NonNull Set<@NonNull Integer>> classId2classIndexes2 = new HashMap<>(classIds);
this.classId2classIndex = classId2classIndex2;
this.classId2classIndexes = classId2classIndexes2;
for (int classIndex = 0; classIndex < classIds; classIndex++) {
ClassId classId = classIndex2classId[classIndex];
classId2classIndex2.put(classId, classIndex);
- Set<Integer> superClassIndexes = new HashSet<Integer>();
+ Set<@NonNull Integer> superClassIndexes = new HashSet<>();
for (int allClassIndex : classIndex2allClassIndexes[classIndex]) {
superClassIndexes.add(allClassIndex);
}
@@ -406,47 +521,58 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
}
}
else {
- this.classId2classIndex = null;
- this.classId2classIndexes = null;
+ this.classId2classIndex = null;
+ this.classId2classIndexes = null;
}
}
/**
- * Add eRootObjects to the modelIndex model.
- */
- @Override
+ * Add eRootObjects to the modelIndex model.
+ */
+ @Override
public void addRootObjects(@NonNull String modelName, @NonNull Iterable<@NonNull ? extends Object> eRootObjects) {
- Integer modelIndex = modelIndexes.get(modelName);
- if (modelIndex == null) {
- throw new IllegalStateException("Unknown model name '" + modelName + "'");
- }
- models[modelIndex].addRootObjects(eRootObjects);
+ Integer modelIndex = modelIndexes.get(modelName);
+ if (modelIndex == null) {
+ throw new IllegalStateException("Unknown model name '" + modelName + "'");
+ }
+ models[modelIndex].addRootObjects(eRootObjects);
}
- /**
- * Create the InvocationManager. Creates a LazyInvocationManager by default.
- */
+ /**
+ * Create the evaluationCache. Creates a EvaluationCache by default.
+ */
+ protected @NonNull EvaluationCache createEvaluationCache() {
+ return new EvaluationCache(executor);
+ }
+
+ /**
+ * Create the InvocationManager. Creates a LazyInvocationManager by default.
+ */
protected @NonNull InvocationManager createInvocationManager() {
return new LazyInvocationManager();
}
- /**
- * Create the ObjectManager. Creates a LazyObjectManager by default.
- */
+ protected SetValue.@NonNull Accumulator createUnenforcedSetAccumulatorValue(@NonNull CollectionTypeId typeId) {
+ return new UnenforcedSetAccumulator(typeId);
+ }
+
+ /**
+ * Create the ObjectManager. Creates a LazyObjectManager by default.
+ */
protected @NonNull ObjectManager createObjectManager() {
return new LazyObjectManager((LazyInvocationManager)invocationManager);
}
@Override
public @NonNull Set<@NonNull Object> get(org.eclipse.ocl.pivot.@NonNull Class type) {
- return new HashSet<@NonNull Object>(models[0].getObjectsOfKind(type));
- }
+ return new UnmodifiableCollectionAsSet<>(models[0].getObjectsOfKind(type));
+ }
/**
* Return the Set of all ClassIndexes to which an EClass instance contributes to allInstances() returns.
*/
private @NonNull Set<@NonNull Integer> getClassIndexes(@NonNull EClass eClass) {
- // ClassId classId = IdManager.getClassId(eClass);
+ // ClassId classId = IdManager.getClassId(eClass);
EPackage ePackage = ClassUtil.nonNullEMF(eClass.getEPackage());
PackageId packageId = IdManager.getPackageId(ePackage);
String className = ClassUtil.nonNullEMF(eClass.getName()); // FIXME Original name
@@ -454,7 +580,7 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
assert classId2classIndexes != null;
Set<@NonNull Integer> classIndexes = classId2classIndexes.get(classId);
if (classIndexes == null) {
- classIndexes = new HashSet<@NonNull Integer>();
+ classIndexes = new HashSet<>();
for (@NonNull EClass eSuperClass : ClassUtil.nullFree(eClass.getESuperTypes())) {
Set<@NonNull Integer> partialResult = getClassIndexes(eSuperClass);
classIndexes.addAll(partialResult);
@@ -466,8 +592,8 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
}
/**
- * Return all objects in the modelIndex model that conform to eClass.
- *
+ * Return all objects in the modelIndex model that conform to eClass.
+ *
protected @NonNull <T extends EObject> List<T> getObjectsByType(int modelIndex, @NonNull EClass eClass) {
return models[modelIndex].getObjectsByType(eClass);
} */
@@ -477,124 +603,138 @@ public abstract class AbstractTransformerInternal extends AbstractModelManager i
* eReference2propertyIndex contains known equivalences and may be updated if more are discovered
* using -1 as a propertyIndex for which no unnavigable opposite is appropriate.
*/
- private @NonNull List<@NonNull Integer> getOppositePropertyIndexes(@NonNull Map<@NonNull EReference, @NonNull Integer> eReference2propertyIndex, @NonNull EClass eClass) {
- List<@NonNull Integer> propertyIndexes = null;
- for (EStructuralFeature eStructuralFeature : eClass.getEAllStructuralFeatures()) {
- if (eStructuralFeature instanceof EReference) {
- EReference eReference = (EReference)eStructuralFeature;
+ private @NonNull List<@NonNull Integer> getOppositePropertyIndexes(@NonNull Map<@NonNull EReference, @NonNull Integer> eReference2propertyIndex, @NonNull EClass eClass) {
+ List<@NonNull Integer> propertyIndexes = null;
+ for (EStructuralFeature eStructuralFeature : eClass.getEAllStructuralFeatures()) {
+ if (eStructuralFeature instanceof EReference) {
+ EReference eReference = (EReference)eStructuralFeature;
Integer propertyIndex = eReference2propertyIndex.get(eReference);
if (propertyIndex == null) {
- if ((eReference.getEOpposite() == null) && !eReference.isDerived() && !eReference.isTransient() && !eReference.isVolatile()) {
- // PropertyId propertyId = IdManager.getPropertyId(eReference);
- EClass eContainingClass = eReference.getEContainingClass();
- EPackage ePackage = ClassUtil.nonNullEMF(eContainingClass.getEPackage());
- PackageId packageId = IdManager.getPackageId(ePackage);
- String className = ClassUtil.nonNullEMF(eContainingClass.getName()); // FIXME Original name
- ClassId classId = packageId.getClassId(className, eContainingClass.getETypeParameters().size());
- String propertyName = ClassUtil.nonNullEMF(eReference.getName()); // FIXME Original name
- PropertyId propertyId = classId.getPropertyId(propertyName);
- assert propertyId2propertyIndex != null;
- propertyIndex = propertyId2propertyIndex.get(propertyId);
- }
- if (propertyIndex == null) {
- propertyIndex = -1;
- }
+ if ((eReference.getEOpposite() == null) && !eReference.isDerived() && !eReference.isTransient() && !eReference.isVolatile()) {
+ // PropertyId propertyId = IdManager.getPropertyId(eReference);
+ EClass eContainingClass = eReference.getEContainingClass();
+ EPackage ePackage = ClassUtil.nonNullEMF(eContainingClass.getEPackage());
+ PackageId packageId = IdManager.getPackageId(ePackage);
+ String className = ClassUtil.nonNullEMF(eContainingClass.getName()); // FIXME Original name
+ ClassId classId = packageId.getClassId(className, eContainingClass.getETypeParameters().size());
+ String propertyName = ClassUtil.nonNullEMF(eReference.getName()); // FIXME Original name
+ PropertyId propertyId = classId.getPropertyId(propertyName);
+ assert propertyId2propertyIndex != null;
+ propertyIndex = propertyId2propertyIndex.get(propertyId);
+ }
+ if (propertyIndex == null) {
+ propertyIndex = -1;
+ }
eReference2propertyIndex.put(eReference, propertyIndex);
}
if (propertyIndex >= 0) {
if (propertyIndexes == null) {
- propertyIndexes = new ArrayList<@NonNull Integer>();
+ propertyIndexes = new ArrayList<>();
}
propertyIndexes.add(propertyIndex);
}
- }
- }
+ }
+ }
return propertyIndexes != null ? propertyIndexes : EMPTY_INDEX_LIST;
}
/**
- * Return all the container-less objects in the modelName model.
- */
- @Override
+ * Return all the container-less objects in the modelName model.
+ */
+ @Override
public @NonNull Collection<@NonNull EObject> getRootEObjects(@NonNull String modelName) {
- Integer modelIndex = modelIndexes.get(modelName);
- if (modelIndex == null) {
- throw new IllegalStateException("Unknown model name '" + modelName + "'");
- }
- List<@NonNull EObject> rootEObjects = new ArrayList<@NonNull EObject>();
- for (@NonNull Object rootObject : models[modelIndex].getRootObjects()) {
- if (rootObject instanceof EObject) {
- rootEObjects.add((EObject)rootObject);
- }
- }
+ Integer modelIndex = modelIndexes.get(modelName);
+ if (modelIndex == null) {
+ throw new IllegalStateException("Unknown model name '" + modelName + "'");
+ }
+ List<@NonNull EObject> rootEObjects = new ArrayList<>();
+ for (@NonNull Object rootObject : models[modelIndex].getRootObjects()) {
+ if (rootObject instanceof EObject) {
+ rootEObjects.add((EObject)rootObject);
+ }
+ }
return rootEObjects;
}
/**
- * Return all the container-less objects in the modelName model.
- */
- @Override
+ * Return all the container-less objects in the modelName model.
+ */
+ @Override
public @NonNull Collection<@NonNull Object> getRootObjects(@NonNull String modelName) {
- Integer modelIndex = modelIndexes.get(modelName);
- if (modelIndex == null) {
- throw new IllegalStateException("Unknown model name '" + modelName + "'");
- }
- return models[modelIndex].getRootObjects();
+ Integer modelIndex = modelIndexes.get(modelName);
+ if (modelIndex == null) {
+ throw new IllegalStateException("Unknown model name '" + modelName + "'");
+ }
+ return models[modelIndex].getRootObjects();
+ }
+
+ /**
+ * The default handler for an exception during mapping execution rethrows an InvocationFailedException so that the
+ * caller may organize a re-exection when the reqired memory access can succeed. Errors are rethrown and should
+ * propagate to the transformation invoker, except for AssertionError which is is absorbed if the user has configured
+ * AbstractTransformer.EXCEPTIONS to observe them on the console. All other exceptions are just absorbed since they
+ * may represent a predicate failure.
+ */
+ protected boolean handleExecutionFailure(@NonNull String mappingName, @NonNull Throwable e) throws InvocationFailedException {
+ if (e instanceof InvocationFailedException) { // Normal case - premature access needs a retry later
+ throw (InvocationFailedException)e;
+ }
+ else if (e instanceof AssertionError) { // Debug case - assertion errors are diagnostic not catastrophic
+ if (debugExceptions) {
+ AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
+ }
+ else {
+ throw (AssertionError)e; // But if the user isn't watching them they are fatal
+ }
+ }
+ else if (e instanceof Error) { // Real errors are fatal
+ if (debugExceptions) {
+ AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
+ }
+ throw (Error)e;
+ }
+ else { // Other failures are just mappings whose predicates were not satisfied.
+ if (e instanceof InvalidValueException) { // Multiway branch to facilitate debugger breakpoints.
+ if (debugExceptions) {
+ AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
+ }
+ }
+ else if (e instanceof NullPointerException) {
+ if (debugExceptions) {
+ AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
+ }
+ }
+ else {
+ if (debugExceptions) {
+ AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
+ }
+ }
+ }
+ return false;
}
- /**
- * The default handler for an exception during mapping execution rethrows an InvocationFailedException so that the
- * caller may organize a re-exection when the reqired memory access can succeed. Errors are rethrown and should
- * propagate to the transformation invoker, except for AssertionError which is is absorbed if the user has configured
- * AbstractTransformer.EXCEPTIONS to observe them on the console. All other exceptions are just absorbed since they
- * may represent a predicate failure.
- */
- protected boolean handleExecutionFailure(@NonNull String mappingName, @NonNull Throwable e) throws InvocationFailedException {
- if (e instanceof InvocationFailedException) { // Normal case - premature access needs a retry later
- throw (InvocationFailedException)e;
- }
- else if (e instanceof AssertionError) { // Debug case - assertion errors are diagnostic not catastrophic
- AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
- if (!AbstractTransformer.EXCEPTIONS.isActive()) {
- throw (AssertionError)e; // But if the user isn't watching them they are fatal
- }
- }
- else if (e instanceof Error) { // Real errors are fatal
- AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
- throw (Error)e;
- }
- else { // Other failures are just mappings whose predicates were not satisfied.
- if (e instanceof InvalidValueException) { // Multiway branch to facilitate debugger breakpoints.
- AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
- }
- else if (e instanceof NullPointerException) {
- AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
- }
- else {
- AbstractTransformer.EXCEPTIONS.println("Execution failure in '" + mappingName + "' : " + e);
- }
- }
- return false;
+ /**
+ * Invoke a mapping with the given constructor with a given set of boundValues once. This shortform of invokeOnce
+ * should only be used when it is known that recursive invocation is impossible.
+ */
+ public <@Nullable T extends Invocation> void invoke(Invocation.@NonNull Constructor constructor, @NonNull Object @NonNull ... boundValues) {
+ @NonNull Invocation invocation = constructor.newInstance(boundValues);
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("invoke " + invocation);
+ }
+ invocationManager.invoke(invocation, true);
+ }
+
+ /**
+ * Invoke a mapping with the given constructor with a given set of boundValues once. Repeated invocation attempts are ignored.
+ */
+ public void invokeOnce(Invocation.@NonNull Constructor constructor, @NonNull Object @NonNull ... boundValues) {
+ @Nullable Invocation invocation = constructor.getFirstInvocation(boundValues);
+ if (invocation != null) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("invokeOnce " + invocation);
+ }
+ invocationManager.invoke(invocation, true);
+ }
}
-
- /**
- * Invoke a mapping with the given constructor with a given set of boundValues once. This shortform of invokeOnce
- * should only be used when it is known that recursive invocation is impossible.
- */
- public <@Nullable T extends Invocation> void invoke(Invocation.@NonNull Constructor constructor, @NonNull Object @NonNull ... boundValues) {
- @NonNull Invocation invocation = constructor.newInstance(boundValues);
- AbstractTransformer.INVOCATIONS.println("invoke " + invocation);
- invocationManager.invoke(invocation, true);
- }
-
- /**
- * Invoke a mapping with the given constructor with a given set of boundValues once. Repeated invocation attempts are ignored.
- */
- public void invokeOnce(Invocation.@NonNull Constructor constructor, @NonNull Object @NonNull ... boundValues) {
- @Nullable Invocation invocation = constructor.getFirstInvocation(boundValues);
- if (invocation != null) {
- AbstractTransformer.INVOCATIONS.println("invokeOnce " + invocation);
- invocationManager.invoke(invocation, true);
- }
- }
}
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalInvocationManager.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalInvocationManager.java
index 6897a70f2..25b39011c 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalInvocationManager.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalInvocationManager.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -40,10 +40,8 @@ public class IncrementalInvocationManager extends AbstractInvocationManager
/**
* Head of doubly linked list of unblocked invocations waiting for a re-execution attempt.
*/
- private @Nullable AbstractInvocationInternal waitingInvocations = null;
+ private @Nullable AbstractInvocationInternal waitingInvocations = null;
- protected final boolean debugTracing = AbstractTransformer.INVOCATIONS.isActive();
-
private synchronized void block(@NonNull Invocation invocation, @NonNull SlotState slotState) {
AbstractInvocationInternal castInvocation = (AbstractInvocationInternal) invocation;
assert castInvocation.debug_blockedBy == null;
@@ -56,7 +54,7 @@ public class IncrementalInvocationManager extends AbstractInvocationManager
castInvocation.insertAfter(blockedInvocations2.prev);
}
slotState.block(invocation);
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("block " + invocation + " for " + slotState);
}
}
@@ -69,7 +67,7 @@ public class IncrementalInvocationManager extends AbstractInvocationManager
return true;
}
do {
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("still blocked " + blockedInvocation + " by " + blockedInvocation.debug_blockedBy);
}
blockedInvocation = blockedInvocation.next;
@@ -77,35 +75,35 @@ public class IncrementalInvocationManager extends AbstractInvocationManager
while (blockedInvocation != blockedInvocations);
return false;
}
-
- private void flushInternal() {
+
+ private void flushInternal() {
while (waitingInvocations != null) {
AbstractInvocationInternal invocation = null;
- synchronized (this) {
- AbstractInvocationInternal waitingInvocations2 = waitingInvocations;
- if (waitingInvocations2 != null) {
- invocation = waitingInvocations2;
- waitingInvocations = waitingInvocations2.next;
- if (waitingInvocations == invocation) {
- waitingInvocations = null;
- }
- invocation.remove();
- }
- }
- if (invocation != null) {
- if (debugTracing) {
- AbstractTransformer.INVOCATIONS.println("re-invoke " + invocation);
- }
- invoke(invocation, false);
- }
- }
- }
-
- @Override
+ synchronized (this) {
+ AbstractInvocationInternal waitingInvocations2 = waitingInvocations;
+ if (waitingInvocations2 != null) {
+ invocation = waitingInvocations2;
+ waitingInvocations = waitingInvocations2.next;
+ if (waitingInvocations == invocation) {
+ waitingInvocations = null;
+ }
+ invocation.remove();
+ }
+ }
+ if (invocation != null) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("re-invoke " + invocation);
+ }
+ invoke(invocation, false);
+ }
+ }
+ }
+
+ @Override
public void invoke(@NonNull Invocation invocation, boolean doFlush) {
try {
invocation.execute();
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("done " + invocation);
}
if (doFlush) {
@@ -113,13 +111,13 @@ public class IncrementalInvocationManager extends AbstractInvocationManager
}
}
catch (InvocationFailedException e) {
- block(invocation, e.slotState);
+ block(invocation, e.slotState);
}
- }
-
+ }
+
@Override
public synchronized void unblock(@NonNull Invocation invocation) {
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("unblock " + invocation);
}
AbstractInvocationInternal castInvocation = (AbstractInvocationInternal) invocation;
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalObjectManager.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalObjectManager.java
index 76739ced5..fb96fd68f 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalObjectManager.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/IncrementalObjectManager.java
@@ -628,8 +628,6 @@ public class IncrementalObjectManager extends AbstractObjectManager
}
}
- protected final boolean debugTracing = AbstractTransformer.INVOCATIONS.isActive();
-
/**
* This unpleasant Map of Maps is a pathfinder before embarking on slotted objects that merge user and overhead
* in a single object. The first map is then a null lookup and the nested map is an index within the object.
@@ -643,7 +641,7 @@ public class IncrementalObjectManager extends AbstractObjectManager
@Override
public synchronized void assigned(@NonNull Object eObject, /*@NonNull*/ EStructuralFeature eFeature, @Nullable Object ecoreValue, @Nullable Object childKey) {
assert eFeature != null;
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("assigned " + eFeature.getEContainingClass().getName() + "::" + eFeature.getName() + " for " + eObject + " = " + ecoreValue);
}
Map<EStructuralFeature, BasicSlotState> objectState = getObjectState(eObject);
@@ -833,7 +831,7 @@ public class IncrementalObjectManager extends AbstractObjectManager
@Override
public synchronized void getting(@NonNull Object eObject, /*@NonNull*/ EStructuralFeature eFeature, boolean isOpposite) {
assert eFeature != null;
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("getting " + eFeature.getEContainingClass().getName() + "::" + eFeature.getName() + " for " + eObject);
}
SlotState slotState = getSlotState(eObject, eFeature);
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyInvocationManager.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyInvocationManager.java
index e5de7df39..db0e8850f 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyInvocationManager.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyInvocationManager.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -40,10 +40,8 @@ public class LazyInvocationManager extends AbstractInvocationManager
/**
* Head of doubly linked list of unblocked invocations waiting for a re-execution attempt.
*/
- private @Nullable AbstractInvocationInternal waitingInvocations = null;
+ private @Nullable AbstractInvocationInternal waitingInvocations = null;
- protected final boolean debugTracing = AbstractTransformer.INVOCATIONS.isActive();
-
private synchronized void block(@NonNull Invocation invocation, @NonNull SlotState slotState) {
AbstractInvocationInternal castInvocation = (AbstractInvocationInternal) invocation;
assert castInvocation.debug_blockedBy == null;
@@ -56,7 +54,7 @@ public class LazyInvocationManager extends AbstractInvocationManager
castInvocation.insertAfter(blockedInvocations2.prev);
}
slotState.block(invocation);
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("block " + invocation + " for " + slotState);
}
}
@@ -69,7 +67,7 @@ public class LazyInvocationManager extends AbstractInvocationManager
return true;
}
do {
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("still blocked " + blockedInvocation + " by " + blockedInvocation.debug_blockedBy);
}
blockedInvocation = blockedInvocation.next;
@@ -77,35 +75,35 @@ public class LazyInvocationManager extends AbstractInvocationManager
while (blockedInvocation != blockedInvocations);
return false;
}
-
- private void flushInternal() {
+
+ private void flushInternal() {
while (waitingInvocations != null) {
AbstractInvocationInternal invocation = null;
- synchronized (this) {
- AbstractInvocationInternal waitingInvocations2 = waitingInvocations;
- if (waitingInvocations2 != null) {
- invocation = waitingInvocations2;
- waitingInvocations = waitingInvocations2.next;
- if (waitingInvocations == invocation) {
- waitingInvocations = null;
- }
- invocation.remove();
- }
- }
- if (invocation != null) {
- if (debugTracing) {
- AbstractTransformer.INVOCATIONS.println("re-invoke " + invocation);
- }
- invoke(invocation, false);
- }
- }
- }
+ synchronized (this) {
+ AbstractInvocationInternal waitingInvocations2 = waitingInvocations;
+ if (waitingInvocations2 != null) {
+ invocation = waitingInvocations2;
+ waitingInvocations = waitingInvocations2.next;
+ if (waitingInvocations == invocation) {
+ waitingInvocations = null;
+ }
+ invocation.remove();
+ }
+ }
+ if (invocation != null) {
+ if (debugInvocations) {
+ AbstractTransformer.INVOCATIONS.println("re-invoke " + invocation);
+ }
+ invoke(invocation, false);
+ }
+ }
+ }
- @Override
+ @Override
public void invoke(@NonNull Invocation invocation, boolean doFlush) {
try {
invocation.execute();
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("done " + invocation);
}
if (doFlush) {
@@ -113,13 +111,13 @@ public class LazyInvocationManager extends AbstractInvocationManager
}
}
catch (InvocationFailedException e) {
- block(invocation, e.slotState);
+ block(invocation, e.slotState);
}
- }
-
+ }
+
@Override
public synchronized void unblock(@NonNull Invocation invocation) {
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("unblock " + invocation);
}
AbstractInvocationInternal castInvocation = (AbstractInvocationInternal) invocation;
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyObjectManager.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyObjectManager.java
index e044da621..c14ac14a9 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyObjectManager.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/internal/tx/LazyObjectManager.java
@@ -715,8 +715,6 @@ public class LazyObjectManager extends AbstractObjectManager
}
}
- protected final boolean debugTracing = AbstractTransformer.INVOCATIONS.isActive();
-
/**
* This unpleasant Map of Maps is a pathfinder before embarking on slotted objects that merge user and overhead
* in a single object. The first map is then a null lookup and the nested map is an index within the object.
@@ -735,7 +733,7 @@ public class LazyObjectManager extends AbstractObjectManager
@Override
public synchronized void assigned(@NonNull Object eObject, /*@NonNull*/ EStructuralFeature eFeature, @Nullable Object ecoreValue, @Nullable Object childKey) {
assert eFeature != null;
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("assigned " + eFeature.getEContainingClass().getName() + "::" + eFeature.getName() + " for " + eObject + " = " + ecoreValue);
}
Map<@NonNull EStructuralFeature, @NonNull SlotState> objectState = getObjectState(eObject);
@@ -802,7 +800,7 @@ public class LazyObjectManager extends AbstractObjectManager
// }
else { // Unidirectional non-containment EReference
if (ecoreValue != null) {
- eOppositeReference = getEOppositeReference(eReference);
+ // eOppositeReference = getEOppositeReference(eReference);
Map<@NonNull EStructuralFeature, @NonNull SlotState> oppositeObjectState = getObjectState(ecoreValue);
slotState = oppositeObjectState.get(eOppositeReference);
if (slotState == null) {
@@ -1015,7 +1013,7 @@ public class LazyObjectManager extends AbstractObjectManager
@Override
public synchronized void getting(@NonNull Object eObject, /*@NonNull*/ EStructuralFeature eFeature, boolean isOpposite) {
assert eFeature != null;
- if (debugTracing) {
+ if (debugInvocations) {
AbstractTransformer.INVOCATIONS.println("getting " + eFeature.getEContainingClass().getName() + "::" + eFeature.getName() + (isOpposite ? "<opposite> " : "") + " for " + eObject);
}
if (isOpposite) {
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/library/model/ModelObjectsOfKindOperation.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/library/model/ModelObjectsOfKindOperation.java
index 0689d5bc2..de5c6c59f 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/library/model/ModelObjectsOfKindOperation.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/library/model/ModelObjectsOfKindOperation.java
@@ -18,7 +18,6 @@
*******************************************************************************/
package org.eclipse.qvtd.doc.minioclcs.xtext.library.model;
-import java.util.ArrayList;
import java.util.Collection;
import org.eclipse.jdt.annotation.NonNull;
@@ -48,6 +47,7 @@ public class ModelObjectsOfKindOperation extends AbstractBinaryOperation
}
TypedModelInstance typedModelInstance = (TypedModelInstance)sourceVal;
Collection<@NonNull ? extends Object> results = typedModelInstance.getObjectsOfKind(type);
- return createSetValue((CollectionTypeId)returnTypeId, new ArrayList<@NonNull Object>(results));
+ return createSetValue((CollectionTypeId)returnTypeId, results);
+ // return createSetValue((CollectionTypeId)returnTypeId, new ArrayList<@NonNull Object>(results));
}
}
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractCS2ASTransformer.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractCS2ASTransformer.java
index ecbcceac4..a5f707fd6 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractCS2ASTransformer.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractCS2ASTransformer.java
@@ -31,11 +31,11 @@ import org.eclipse.qvtd.doc.minioclcs.xtext.tx.AbstractTransformer;
public abstract class AbstractCS2ASTransformer extends AbstractTransformer
- implements CS2ASTransformer
+implements CS2ASTransformer
{
- private final List<CS2ASDiagnostic> txErrors = new ArrayList<CS2ASDiagnostic>();
-
+ private final List<CS2ASDiagnostic> txErrors = new ArrayList<CS2ASDiagnostic>();
+
protected AbstractCS2ASTransformer(@NonNull Executor executor, @NonNull String @NonNull [] modelNames,
@NonNull PropertyId @Nullable [] propertyIndex2propertyId, @NonNull ClassId @Nullable [] classIndex2classId, int @Nullable [] @NonNull [] classIndex2allClassIndexes) {
super(executor, modelNames, propertyIndex2propertyId, classIndex2classId, classIndex2allClassIndexes);
@@ -44,34 +44,39 @@ public abstract class AbstractCS2ASTransformer extends AbstractTransformer
protected @NonNull RuntimeException throwNull(@NonNull EObject csObject, @NonNull String message) {
throw new CS2ASException(csObject, message);
}
-
- protected void handleLookupError(EObject sourceObject, String lookupHint) {
- handleError(sourceObject, "''" + lookupHint +"'' not found");
+
+ protected void handleLookupError(@Nullable String mentor, String lookupHint) {
+ throw new RuntimeException(mentor + lookupHint);
}
-
+
protected void handleLookupError(EObject sourceObject, EObject lookupHint) {
handleError(sourceObject, "''" + lookupHint.toString() +"'' not found");
}
-
+
+ protected void handleLookupError(@Nullable Object aPathElementCS_0,
+ @Nullable String name_1) {
+ throw new RuntimeException(aPathElementCS_0 + name_1);
+ }
+
protected void handleLookupError(List<? extends EObject> sourceObjects, EObject lookupHint) {
int hintPos = sourceObjects.indexOf(lookupHint);
switch (hintPos) {
case -1:
case 0:
- hintPos = 0; // For safety, the default will be the first one
- break;
+ hintPos = 0; // For safety, the default will be the first one
+ break;
default:
- // We assume the element from which we report is the previous one of the lookupHint
- hintPos = hintPos -1;
+ // We assume the element from which we report is the previous one of the lookupHint
+ hintPos = hintPos -1;
}
-
- handleError(sourceObjects.get(hintPos), "''" + lookupHint.toString() +"'' not found");
+
+ handleError(sourceObjects.get(hintPos), "''" + lookupHint.toString() +"'' not found");
}
-
+
protected void handleError(EObject sourceObject, String errorMessage) {
txErrors.add(new CS2ASDiagnostic(sourceObject, errorMessage));
}
-
+
@Override
public List<CS2ASDiagnostic> getErrors() {
return txErrors;
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocation.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocation.java
index fcaa0f281..30e908ded 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocation.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocation.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -44,7 +44,7 @@ public abstract class AbstractInvocation extends AbstractInvocationInternal
@Override
public void addCreatedObject(@NonNull Object createdObject) {
if (createdObjects == null) {
- createdObjects = new HashSet<@NonNull Object>();
+ createdObjects = new HashSet<>();
}
createdObjects.add(createdObject);
}
@@ -52,7 +52,7 @@ public abstract class AbstractInvocation extends AbstractInvocationInternal
@Override
public void addReadSlot(SlotState.@NonNull Incremental readSlot) {
if (readSlots == null) {
- readSlots = new HashSet<SlotState.@NonNull Incremental>();
+ readSlots = new HashSet<>();
}
readSlots.add(readSlot);
readSlot.addTargetInternal(this);
@@ -61,7 +61,7 @@ public abstract class AbstractInvocation extends AbstractInvocationInternal
@Override
public void addWriteSlot(SlotState.@NonNull Incremental writeSlot) {
if (writeSlots == null) {
- writeSlots = new HashSet<SlotState.@NonNull Incremental>();
+ writeSlots = new HashSet<>();
}
writeSlots.add(writeSlot);
writeSlot.addSourceInternal(this);
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocationManager.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocationManager.java
index c2a8ad039..54011d194 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocationManager.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractInvocationManager.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -25,6 +25,8 @@ import org.eclipse.jdt.annotation.NonNull;
*/
public abstract class AbstractInvocationManager implements InvocationManager
{
+ protected final boolean debugInvocations = AbstractTransformer.INVOCATIONS.isActive();
+
@Override
public <R> R accept(@NonNull ExecutionVisitor<R> visitor) {
return visitor.visitInvocationManager(this);
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractObjectManager.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractObjectManager.java
index 2d289baef..f475289ef 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractObjectManager.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/AbstractObjectManager.java
@@ -12,7 +12,7 @@
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
- *
+ *
* Contributors:
* E.D.Willink - Initial API and implementation
*******************************************************************************/
@@ -32,7 +32,8 @@ public abstract class AbstractObjectManager implements ObjectManager
protected static final @NonNull List<@NonNull SlotState> EMPTY_SLOT_STATE_LIST = Collections.emptyList();
protected final @NonNull InvocationManager invocationManager;
-
+ protected final boolean debugInvocations = AbstractTransformer.INVOCATIONS.isActive();
+
protected AbstractObjectManager(@NonNull InvocationManager invocationManager) {
this.invocationManager = invocationManager;
}
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/TypedModelInstance.java b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/TypedModelInstance.java
index 6fa0278d6..c0d7d14b7 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/TypedModelInstance.java
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src-gen/org/eclipse/qvtd/doc/minioclcs/xtext/tx/TypedModelInstance.java
@@ -26,8 +26,7 @@ import org.eclipse.jdt.annotation.Nullable;
/**
* A TypedModelInstance makes an input or output model of an executing transformation
* accessible as a model instance.
- *
- * at-since 1.1
+ *
* @noimplement clients should derive from AbstractTypedModelInstance
*/
public interface TypedModelInstance
diff --git a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src/org/eclipse/qvtd/doc/GenerateMiniOCLCS.mwe2 b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src/org/eclipse/qvtd/doc/GenerateMiniOCLCS.mwe2
index c43f57d22..aaeb94e6c 100644
--- a/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src/org/eclipse/qvtd/doc/GenerateMiniOCLCS.mwe2
+++ b/doc/org.eclipse.qvtd.doc.minioclcs.xtext/src/org/eclipse/qvtd/doc/GenerateMiniOCLCS.mwe2
@@ -52,10 +52,9 @@ Workflow {
}
- outline = CS2ASOutlineTreeProviderFragment {
-
- }
-
+// outline = CS2ASOutlineTreeProviderFragment {
+//
+// }
}
}
}

Back to the top