Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.qvtd.codegen/src/org/eclipse/qvtd/codegen/qvti/java/QVTiCG2JavaVisitor.java48
-rw-r--r--plugins/org.eclipse.qvtd.debug/src/org/eclipse/qvtd/debug/launching/QVTiLaunchConfigurationDelegate.java4
-rw-r--r--plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/BasicQVTiExecutor.java2
-rw-r--r--plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/Execution2GraphVisitor.java107
-rw-r--r--plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/QVTiIncrementalExecutor.java6
-rw-r--r--plugins/org.eclipse.qvtd.runtime/src/org/eclipse/qvtd/runtime/evaluation/AbstractInvocation.java8
6 files changed, 100 insertions, 75 deletions
diff --git a/plugins/org.eclipse.qvtd.codegen/src/org/eclipse/qvtd/codegen/qvti/java/QVTiCG2JavaVisitor.java b/plugins/org.eclipse.qvtd.codegen/src/org/eclipse/qvtd/codegen/qvti/java/QVTiCG2JavaVisitor.java
index 888dbf3bf..5564a6dbb 100644
--- a/plugins/org.eclipse.qvtd.codegen/src/org/eclipse/qvtd/codegen/qvti/java/QVTiCG2JavaVisitor.java
+++ b/plugins/org.eclipse.qvtd.codegen/src/org/eclipse/qvtd/codegen/qvti/java/QVTiCG2JavaVisitor.java
@@ -405,6 +405,7 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
}
protected void doCreateIncrementalManagers() {
+ js.append("@Override\n");
js.append("protected ");
js.appendIsRequired(true);
js.append(" ");
@@ -417,6 +418,7 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
js.popIndentation();
js.append("}\n");
js.append("\n");
+ js.append("@Override\n");
js.append("protected ");
js.appendIsRequired(true);
js.append(" ");
@@ -856,7 +858,12 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
if (useGot) {
EPackage ePackage = ClassUtil.nonNullModel(eStructuralFeature.getEContainingClass().getEPackage());
//
- js.append("objectManager.got(this, ");
+ js.append("objectManager.got(");
+ if (localPrefix != null) {
+ js.append(localPrefix);
+ js.append(".");
+ }
+ js.append("this, ");
js.appendValueName(source);
js.append(", ");
js.appendClassReference(genModelHelper.getQualifiedPackageInterfaceName(ePackage));
@@ -869,6 +876,7 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
}
protected void doIsEqual(@NonNull List<@NonNull ? extends CGParameter> cgFreeVariables) {
+ js.append("@Override\n");
js.append("public boolean isEqual(");
js.appendIsRequired(true);
js.append(" ");
@@ -880,14 +888,19 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
js.append(" [] thoseValues) {\n");
js.pushIndentation(null);
js.append("return ");
- int index = 0;
- for (@NonNull CGParameter cgFreeVariable : cgFreeVariables) {
- if (index > 0) {
- js.append("\n && ");
+ if (cgFreeVariables.size() > 0) {
+ int index = 0;
+ for (@NonNull CGParameter cgFreeVariable : cgFreeVariables) {
+ if (index > 0) {
+ js.append("\n && ");
+ }
+ js.append("idResolver.oclEquals(");
+ js.append(cgFreeVariable.getValueName());
+ js.append(", thoseValues[" + index++ + "])");
}
- js.append("idResolver.oclEquals(");
- js.append(cgFreeVariable.getValueName());
- js.append(", thoseValues[" + index++ + "])");
+ }
+ else {
+ js.append("true");
}
js.append(";\n");
js.popIndentation();
@@ -908,7 +921,7 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
js.pushIndentation(null);
String savedLocalPrefix = localPrefix;
try {
- localPrefix = hasMappingClass ? cgMapping.getTransformation().getName() : localPrefix;
+ localPrefix = hasMappingClass ? getMappingName(cgMapping) : localPrefix;
if (!cgBody.isInlined()) {
cgBody.accept(this);
}
@@ -1109,8 +1122,18 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
js.append("public boolean run() {\n");
js.pushIndentation(null);
js.append("return ");
- js.append(getMappingName(cgRootMapping));
- js.append("() && invocationManager.flush();\n");
+ if (isIncremental) {
+ js.append("new ");
+ js.append(getMappingName(cgRootMapping));
+ js.append("(new ");
+ js.appendIsRequired(true);
+ js.append(" Object[0]).execute()");
+ }
+ else {
+ js.append(getMappingName(cgRootMapping));
+ js.append("()");
+ }
+ js.append(" && invocationManager.flush();\n");
js.popIndentation();
js.append("}\n");
}
@@ -1615,7 +1638,7 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
List<@NonNull CGGuardVariable> cgFreeVariables = ClassUtil.nullFree(cgMapping.getFreeVariables());
//
js.appendCommentWithOCL(null, cgMapping.getAst());
- if (useClass(cgMapping) && (cgFreeVariables.size() > 0)) {
+ if (useClass(cgMapping) /*&& (cgFreeVariables.size() > 0)*/) {
js.append("protected class ");
js.append(getMappingName(cgMapping));
js.append(" extends ");
@@ -1631,6 +1654,7 @@ public class QVTiCG2JavaVisitor extends CG2JavaVisitor<@NonNull QVTiCodeGenerato
js.append("\n");
doMappingConstructor(cgMapping);
js.append("\n");
+ js.append("@Override\n");
js.append("public boolean execute() ");
doMappingBody(cgMapping, true);
js.append("\n");
diff --git a/plugins/org.eclipse.qvtd.debug/src/org/eclipse/qvtd/debug/launching/QVTiLaunchConfigurationDelegate.java b/plugins/org.eclipse.qvtd.debug/src/org/eclipse/qvtd/debug/launching/QVTiLaunchConfigurationDelegate.java
index 9b2f6e6d6..a4a9c0c71 100644
--- a/plugins/org.eclipse.qvtd.debug/src/org/eclipse/qvtd/debug/launching/QVTiLaunchConfigurationDelegate.java
+++ b/plugins/org.eclipse.qvtd.debug/src/org/eclipse/qvtd/debug/launching/QVTiLaunchConfigurationDelegate.java
@@ -40,9 +40,9 @@ import org.eclipse.qvtd.debug.QVTiDebugPlugin;
import org.eclipse.qvtd.debug.core.QVTiDebugCore;
import org.eclipse.qvtd.pivot.qvtbase.TypedModel;
import org.eclipse.qvtd.pivot.qvtimperative.ImperativeTransformation;
-import org.eclipse.qvtd.pivot.qvtimperative.evaluation.BasicQVTiExecutor;
import org.eclipse.qvtd.pivot.qvtimperative.evaluation.QVTiEnvironmentFactory;
import org.eclipse.qvtd.pivot.qvtimperative.evaluation.QVTiExecutor;
+import org.eclipse.qvtd.pivot.qvtimperative.evaluation.QVTiIncrementalExecutor;
import org.eclipse.qvtd.pivot.qvtimperative.utilities.QVTimperativeUtil;
public class QVTiLaunchConfigurationDelegate extends LaunchConfigurationDelegate implements QVTiLaunchConstants
@@ -51,7 +51,7 @@ public class QVTiLaunchConfigurationDelegate extends LaunchConfigurationDelegate
protected static final IStatus fgLaunchErrorStatus = new Status(IStatus.ERROR, QVTiDebugPlugin.PLUGIN_ID, LAUNCH_ERROR_CODE, "Launch configuration error", null); //$NON-NLS-1$
protected @NonNull QVTiExecutor createExecutor(@NonNull QVTiEnvironmentFactory envFactory, @NonNull ImperativeTransformation transformation) {
- return new BasicQVTiExecutor(envFactory, transformation);
+ return new QVTiIncrementalExecutor(envFactory, transformation, QVTiIncrementalExecutor.Mode.LAZY);
}
protected @NonNull QVTiDebugCore getDebugCore() {
diff --git a/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/BasicQVTiExecutor.java b/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/BasicQVTiExecutor.java
index a5f2694b6..012a66543 100644
--- a/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/BasicQVTiExecutor.java
+++ b/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/BasicQVTiExecutor.java
@@ -65,7 +65,7 @@ import org.eclipse.qvtd.pivot.qvtimperative.utilities.QVTimperativeUtil;
import org.eclipse.qvtd.runtime.evaluation.AbstractTransformer;
import org.eclipse.qvtd.runtime.evaluation.InvocationFailedException;
-public class BasicQVTiExecutor extends AbstractExecutor implements QVTiExecutor
+public abstract class BasicQVTiExecutor extends AbstractExecutor implements QVTiExecutor
{
protected final @NonNull ImperativeTransformation transformation;
private @Nullable QVTiTransformationAnalysis transformationAnalysis = null;
diff --git a/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/Execution2GraphVisitor.java b/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/Execution2GraphVisitor.java
index 3b8195d35..bc8e14e91 100644
--- a/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/Execution2GraphVisitor.java
+++ b/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/Execution2GraphVisitor.java
@@ -4,7 +4,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
******************************************************************************/
@@ -73,15 +73,15 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
protected static @NonNull String NULL_PLACEHOLDER = "\"<null>\""; //$NON-NLS-1$
protected final @NonNull GraphStringBuilder context;
-
- private Map<AssociationStatus, String> associationId = new HashMap<AssociationStatus, String>();
- private Map<ClassStatus, String> classId = new HashMap<ClassStatus, String>();
- private Map<Invocation, GraphNode> invocation2node = new HashMap<Invocation, GraphNode>();
- private Map<Object, GraphNode> object2node = new HashMap<Object, GraphNode>();
- private Map<SlotState, GraphNode> slot2node = new HashMap<SlotState, GraphNode>();
-// private Map<String, String> propertyId2associationId = new HashMap<String, String>();
-// private Map<String, PropertyStatus> associationId2propertyStatus = new HashMap<String, PropertyStatus>();
-
+
+ private Map<@NonNull AssociationStatus, @NonNull String> associationId = new HashMap<>();
+ private Map<@NonNull ClassStatus, @NonNull String> classId = new HashMap<>();
+ private Map<@NonNull Invocation, @NonNull GraphNode> invocation2node = new HashMap<>();
+ private Map<@NonNull Object, @NonNull GraphNode> object2node = new HashMap<>();
+ private Map<@NonNull SlotState, @NonNull GraphNode> slot2node = new HashMap<>();
+ // private Map<@NonNull String, @NonNull String> propertyId2associationId = new HashMap<>();
+ // private Map<@NonNull String, @NonNull PropertyStatus> associationId2propertyStatus = new HashMap<>();
+
public Execution2GraphVisitor(@NonNull GraphStringBuilder s) {
this.context = s;
}
@@ -98,7 +98,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return associationStatus.isIsOutput() ? "#cc80ff" : "#cc0000";
}
}
-
+
protected @NonNull String getAssociationId(@NonNull AssociationStatus object) {
String id = associationId.get(object);
if (id == null) {
@@ -137,7 +137,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return classStatus.isIsOutput() ? "#cc80ff" : "#cc0000";
}
}
-
+
protected @NonNull String getClassId(@NonNull ClassStatus object) {
String id = classId.get(object);
if (id == null) {
@@ -150,14 +150,14 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
protected @NonNull GraphNode getInvocationNode(@NonNull Invocation object) {
GraphNode node = invocation2node.get(object);
if (node == null) {
-// id = object.getReferredMappingCall().getReferredMapping().getName() + "-" + (mappingId.size() + 1);
+ // id = object.getReferredMappingCall().getReferredMapping().getName() + "-" + (mappingId.size() + 1);
final String label;
if (object instanceof EObject) {
label = ((EObject)object).eClass().getName() + "-" + (invocation2node.size() + 1);
}
else {
label = object.toString().replace("@", "\n@");
-// label = object.getClass().getSimpleName() + "-" + (invocation2node.size() + 1);
+ // label = object.getClass().getSimpleName() + "-" + (invocation2node.size() + 1);
}
node = new GraphNode()
{
@@ -166,7 +166,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
s.setLabel(label);
s.setShape("hexagon");
s.setColor("orange");
-// context.appendNode(mappingId, "hexagon", "#ffcc00", 30, 150, mappingId.replace("-", "\n"));
+ // context.appendNode(mappingId, "hexagon", "#ffcc00", 30, 150, mappingId.replace("-", "\n"));
s.appendAttributedNode(nodeName);
}
};
@@ -176,17 +176,17 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return node;
}
- protected @NonNull GraphNode getObjectNode(@NonNull Object object) {
+ protected @NonNull GraphNode getObjectNode(@NonNull Object object, @NonNull String color) {
GraphNode node = object2node.get(object);
if (node == null) {
-// id = object.getReferredMappingCall().getReferredMapping().getName() + "-" + (mappingId.size() + 1);
+ // id = object.getReferredMappingCall().getReferredMapping().getName() + "-" + (mappingId.size() + 1);
final String label;
if (object instanceof EObject) {
label = ((EObject)object).eClass().getName() + "-" + (object2node.size() + 1);
}
else {
label = object.toString().replace("@", "\n@");
-// label = object.getClass().getSimpleName() + "-" + (invocation2node.size() + 1);
+ // label = object.getClass().getSimpleName() + "-" + (invocation2node.size() + 1);
}
node = new GraphNode()
{
@@ -194,7 +194,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
public void appendNode(@NonNull GraphStringBuilder s, @NonNull String nodeName) {
s.setLabel(label);
s.setShape("rectangle");
- s.setColor("blue");
+ s.setColor(color);
s.appendAttributedNode(nodeName);
}
};
@@ -216,7 +216,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
}
}
- protected @NonNull GraphNode getSlotNode(SlotState.@NonNull Incremental object) {
+ protected @NonNull GraphNode getSlotNode(SlotState.@NonNull Incremental object, @NonNull String color) {
if (object.getValue() != null) {
object = object.getPrimarySlotState();
}
@@ -240,7 +240,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
if (eFeature instanceof EAttribute) {
s.setStyle("rounded");
}
- s.setColor("blue");
+ s.setColor(color);
s.appendAttributedNode(nodeName);
}
};
@@ -250,13 +250,13 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return node;
}
-/* @Override
+ /* @Override
public String visiting(@NonNull EvaluationElement visitable) {
// append(visitable.getClass().getName());
return null;
} */
-/* @Override
+ /* @Override
public @Nullable String visitAssociationStatus(@NonNull AssociationStatus object) {
String associationId = getAssociationId(object);
String fillColor = object.isIsError() ? "#ff0000" : getAssociationColor(object);
@@ -277,7 +277,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return null;
} */
-/* @Override
+ /* @Override
public @Nullable String visitAttributeStatus(@NonNull AttributeStatus object) {
ClassStatus classStatus = object.getOwningClassStatus();
assert classStatus != null;
@@ -301,7 +301,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return null;
} */
-/* @Override
+ /* @Override
public @Nullable String visitClassStatus(@NonNull ClassStatus object) {
String classId = getClassId(object);
context.appendNode(classId, "rectangle", getClassColor(object), 30, 120, classId.replace("-", "\n"));
@@ -313,8 +313,9 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
@Override
public @Nullable String visitInvocation(@NonNull Invocation object) {
+ @SuppressWarnings("unused")
GraphNode invocationNode = getInvocationNode(object);
-/* context.appendNode(mappingId, "hexagon", "#ffcc00", 30, 150, mappingId.replace("-", "\n"));
+ /* context.appendNode(mappingId, "hexagon", "#ffcc00", 30, 150, mappingId.replace("-", "\n"));
for (ElementStatus inputStatus : object.getInputs()) {
if (inputStatus instanceof ClassStatus) {
ClassStatus classStatus = (ClassStatus)inputStatus;
@@ -344,28 +345,28 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
@Override
public @Nullable String visitInvocationManager(@NonNull InvocationManager object) {
-// context.open();
-// for (ClassStatus classStatus : object.getOwnedClassStatuses()) {
-// classStatus.accept(this);
-// }
-// for (MappingStatus mappingStatus : object.getOwnedMappingStatuses()) {
-// mappingStatus.accept(this);
-// }
-// for (AssociationStatus associationStatus : object.getOwnedAssociationStatuses()) {
-// associationStatus.accept(this);
-// }
-// context.close();
+ // context.open();
+ // for (ClassStatus classStatus : object.getOwnedClassStatuses()) {
+ // classStatus.accept(this);
+ // }
+ // for (MappingStatus mappingStatus : object.getOwnedMappingStatuses()) {
+ // mappingStatus.accept(this);
+ // }
+ // for (AssociationStatus associationStatus : object.getOwnedAssociationStatuses()) {
+ // associationStatus.accept(this);
+ // }
+ // context.close();
return null;
}
@Override
public @Nullable String visitObjectManager(@NonNull ObjectManager objectManager) {
- Set<Invocation.@NonNull Incremental> allInvocations = new HashSet<Invocation.@NonNull Incremental>();
- Set<SlotState.@NonNull Incremental> allSlots = new HashSet<SlotState.@NonNull Incremental>();
- Map<@NonNull Object, List<SlotState.@NonNull Incremental>> object2slots = new HashMap<@NonNull Object, List<SlotState.@NonNull Incremental>>();
- for (Object object : objectManager.getObjects()) {
- List<SlotState.Incremental> objectSlots = new ArrayList<SlotState.Incremental>();
- for (SlotState slotState : objectManager.getSlotStates(object)) {
+ Set<Invocation.@NonNull Incremental> allInvocations = new HashSet<>();
+ Set<SlotState.@NonNull Incremental> allSlots = new HashSet<>();
+ Map<@NonNull Object, @NonNull List<SlotState.@NonNull Incremental>> object2slots = new HashMap<>();
+ for (@NonNull Object object : objectManager.getObjects()) {
+ List<SlotState.@NonNull Incremental> objectSlots = new ArrayList<>();
+ for (@NonNull SlotState slotState : objectManager.getSlotStates(object)) {
if (slotState instanceof SlotState.Incremental) {
allSlots.add((SlotState.Incremental)slotState);
objectSlots.add((SlotState.Incremental)slotState);
@@ -381,28 +382,28 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
for (Invocation.@NonNull Incremental invocation : allInvocations) {
invocation.accept(this);
GraphNode invocationNode = getInvocationNode(invocation);
- for (Object createdObject : invocation.getCreatedObjects()) {
- GraphNode objectNode = getObjectNode(createdObject);
+ for (@NonNull Object createdObject : invocation.getCreatedObjects()) {
+ GraphNode objectNode = getObjectNode(createdObject, "green");
appendEdge(invocationNode, objectNode, "green");
}
}
for (SlotState.@NonNull Incremental slotState : allSlots) {
- GraphNode slotNode = getSlotNode(slotState);
+ GraphNode slotNode = getSlotNode(slotState, "green");
slotState.accept(this);
- for (Invocation invocation : slotState.getSources()) {
+ for (@NonNull Invocation invocation : slotState.getSources()) {
appendEdge(getInvocationNode(invocation), slotNode, "green");
}
- for (Invocation invocation : slotState.getTargets()) {
+ for (@NonNull Invocation invocation : slotState.getTargets()) {
appendEdge(slotNode, getInvocationNode(invocation), "cyan");
}
Iterables.addAll(allInvocations, slotState.getTargets());
}
- for (Object object : objectManager.getObjects()) {
- GraphNode objectNode = getObjectNode(object);
+ for (@NonNull Object object : objectManager.getObjects()) {
+ GraphNode objectNode = getObjectNode(object, "blue");
List<SlotState.@NonNull Incremental> slots = object2slots.get(object);
if (slots != null) {
for (SlotState.@NonNull Incremental slotState : slots) {
- GraphNode slotNode = getSlotNode(slotState);
+ GraphNode slotNode = getSlotNode(slotState, "blue");
slotState.accept(this);
appendEdge(objectNode, slotNode, "blue");
}
@@ -413,7 +414,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
@Override
public @Nullable String visitSlotState(@NonNull SlotState object) {
- GraphNode slotNode = getSlotNode((SlotState.@NonNull Incremental) object);
+ // GraphNode slotNode = getSlotNode((SlotState.@NonNull Incremental) object, "orange");
return null;
}
@@ -422,7 +423,7 @@ public class Execution2GraphVisitor extends AbstractExecutionVisitor<String>
return null;
}
-/* @Override
+ /* @Override
public @Nullable String visitTransformationStatus(@NonNull TransformationStatus object) {
context.open();
for (ClassStatus classStatus : object.getOwnedClassStatuses()) {
diff --git a/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/QVTiIncrementalExecutor.java b/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/QVTiIncrementalExecutor.java
index 2fd810dcd..f4edb7c3c 100644
--- a/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/QVTiIncrementalExecutor.java
+++ b/plugins/org.eclipse.qvtd.pivot.qvtimperative/src/org/eclipse/qvtd/pivot/qvtimperative/evaluation/QVTiIncrementalExecutor.java
@@ -104,7 +104,7 @@ public class QVTiIncrementalExecutor extends BasicQVTiExecutor
@NonNull Function asFunction, @Nullable Object @NonNull [] boxedSourceAndArgumentValues) {
Map<@NonNull Operation, Computation.@NonNull Constructor> operation2computationConstructor2 = operation2computationConstructor;
if (operation2computationConstructor2 == null) {
- operation2computationConstructor = operation2computationConstructor2 = new HashMap<@NonNull Operation, Computation.@NonNull Constructor>();
+ operation2computationConstructor = operation2computationConstructor2 = new HashMap<>();
}
Computation.Constructor computationConstructor = operation2computationConstructor2.get(asFunction);
if (computationConstructor == null) {
@@ -159,7 +159,7 @@ public class QVTiIncrementalExecutor extends BasicQVTiExecutor
}
Map<@NonNull Mapping, Invocation.@NonNull Constructor> mapping2invocationConstructor2 = mapping2invocationConstructor;
if (mapping2invocationConstructor2 == null) {
- mapping2invocationConstructor = mapping2invocationConstructor2 = new HashMap<@NonNull Mapping, Invocation.@NonNull Constructor>();
+ mapping2invocationConstructor = mapping2invocationConstructor2 = new HashMap<>();
}
Invocation.Constructor invocationConstructor = mapping2invocationConstructor2.get(asMapping);
if (invocationConstructor == null) {
@@ -199,7 +199,7 @@ public class QVTiIncrementalExecutor extends BasicQVTiExecutor
@Override
public String toString() {
- return mappingCall.getReferredMapping().getName() + "@" + Integer.toHexString(System.identityHashCode(this));
+ return mappingCall.getReferredMapping().getName();// + "@" + Integer.toHexString(System.identityHashCode(this));
}
};
return invocation;
diff --git a/plugins/org.eclipse.qvtd.runtime/src/org/eclipse/qvtd/runtime/evaluation/AbstractInvocation.java b/plugins/org.eclipse.qvtd.runtime/src/org/eclipse/qvtd/runtime/evaluation/AbstractInvocation.java
index 2c0776e92..6aaa90014 100644
--- a/plugins/org.eclipse.qvtd.runtime/src/org/eclipse/qvtd/runtime/evaluation/AbstractInvocation.java
+++ b/plugins/org.eclipse.qvtd.runtime/src/org/eclipse/qvtd/runtime/evaluation/AbstractInvocation.java
@@ -4,7 +4,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
*******************************************************************************/
@@ -36,7 +36,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);
}
@@ -44,7 +44,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);
@@ -53,7 +53,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);

Back to the top