Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2016-10-06 16:20:18 +0000
committerHenrik Rentz-Reichert2016-10-06 16:22:53 +0000
commitced59bf8e7c26a931cbc77cc4a7c3247a0568d36 (patch)
tree1fbca9496a86b53876a0a76f331dd053f26d6a1a /plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core
parentaf4788aee242cd5872948f5eb9df6352437a0031 (diff)
downloadorg.eclipse.etrice-ced59bf8e7c26a931cbc77cc4a7c3247a0568d36.tar.gz
org.eclipse.etrice-ced59bf8e7c26a931cbc77cc4a7c3247a0568d36.tar.xz
org.eclipse.etrice-ced59bf8e7c26a931cbc77cc4a7c3247a0568d36.zip
Bug 501587 - [room] validation of communication type is not
comprehensible Improved message and added quick fix. Change-Id: I6916a31e180ef5eebbc70c692ea8c064747a12ee
Diffstat (limited to 'plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core')
-rw-r--r--plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core/ui/quickfix/RoomQuickfixProvider.java13
1 files changed, 13 insertions, 0 deletions
diff --git a/plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core/ui/quickfix/RoomQuickfixProvider.java b/plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core/ui/quickfix/RoomQuickfixProvider.java
index d3243f166..a0ac0f64f 100644
--- a/plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core/ui/quickfix/RoomQuickfixProvider.java
+++ b/plugins/org.eclipse.etrice.core.room.ui/src/org/eclipse/etrice/core/ui/quickfix/RoomQuickfixProvider.java
@@ -28,6 +28,8 @@ import org.eclipse.etrice.core.common.base.KeyValue;
import org.eclipse.etrice.core.common.base.RealLiteral;
import org.eclipse.etrice.core.common.base.SimpleAnnotationAttribute;
import org.eclipse.etrice.core.common.base.StringLiteral;
+import org.eclipse.etrice.core.fsm.fSM.ComponentCommunicationType;
+import org.eclipse.etrice.core.room.ActorClass;
import org.eclipse.etrice.core.room.ActorRef;
import org.eclipse.etrice.core.room.ReferenceType;
import org.eclipse.etrice.core.room.StandardOperation;
@@ -330,5 +332,16 @@ public class RoomQuickfixProvider extends DefaultQuickfixProvider {
}
});
}
+
+ @Fix(RoomJavaValidator.INCONSISTENT_COMMUNICATION_TYPE)
+ public void makeActorClassCommTypeLikeBaseClass(final Issue issue, IssueResolutionAcceptor acceptor) {
+ acceptor.accept(issue, "Set communication type as for base class.", issue.getData()[0]+" ActorClass "+issue.getData()[1]+" ...", "correction_change.gif", new ISemanticModification() {
+ @Override
+ public void apply(EObject element, IModificationContext context) throws Exception {
+ ActorClass ac = (ActorClass) element;
+ ac.setCommType(ComponentCommunicationType.get(issue.getData()[0]));
+ }
+ });
+ }
}

Back to the top