Commit 0b3732aa authored by Alexander Diewald's avatar Alexander Diewald

Merge remote-tracking branch 'origin/master' into 3980

Conflicts:
	org.fortiss.af3.platform.hierarchic/src/org/fortiss/af3/platform/hierarchic/compose/.ratings
	org.fortiss.af3.platform.hierarchic/src/org/fortiss/af3/platform/hierarchic/compose/HierarchicalCompositionRules.java
Signed-off-by: Alexander Diewald's avatarAlexander Diewald <diewald@fortiss.org>
parents 41d2ef9e e5608adf
ComponentControllerFactory.java 57c48af3d6c2d51a9040a8b754a8b19b73525777 GREEN
ComponentModelFactory.java 9141373b9498b8e947ef1ca8921128bdf66ec308 GREEN
ComponentStructureFXEditor.java 2d7c0f40fffb4cfb918b60da5de3d5fc0c067916 GREEN
ComponentStructureFXEditor.java c9016fd1b30ee8ed98cace186615c03ccb894abc GREEN
ComponentStructureFXEditorBinding.java 19ca73be6a4ea974994d26db537329878748b20d GREEN
ComponentVisualFactory.java 5422167d12bb5553ed816363d41e0288fe481056 GREEN
ComponentVisualFactory.java c784b5e87c08abc9a3e201c11bc08b93fce20f6a GREEN
......@@ -18,10 +18,10 @@ package org.fortiss.af3.component.ui.editor.fx;
import static javafx.scene.paint.Color.LIGHTGRAY;
import org.eclipse.emf.ecore.EObject;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramViewerFeatures;
import org.fortiss.af3.component.model.Component;
import org.fortiss.af3.component.model.InputPort;
import org.fortiss.af3.component.model.OutputPort;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramViewerFeatures;
import org.fortiss.tooling.kernel.ui.extension.base.LWFXEFEditorBase;
import javafx.geometry.Dimension2D;
......
......@@ -15,6 +15,13 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.component.ui.editor.fx;
import org.fortiss.af3.component.model.Channel;
import org.fortiss.af3.component.model.Component;
import org.fortiss.af3.component.model.Port;
import org.fortiss.af3.component.ui.editor.fx.visual.ChannelVisual;
import org.fortiss.af3.component.ui.editor.fx.visual.ContentComponentPortVisual;
import org.fortiss.af3.component.ui.editor.fx.visual.ContentComponentVisual;
import org.fortiss.af3.component.ui.editor.fx.visual.DiagramComponentPortVisual;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramAnchorageMVCBundle;
......@@ -24,13 +31,6 @@ import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.IContentVisual;
import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.IDiagramAnchorageVisual;
import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.ILinkVisual;
import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.IVisualFactory;
import org.fortiss.af3.component.model.Channel;
import org.fortiss.af3.component.model.Component;
import org.fortiss.af3.component.model.Port;
import org.fortiss.af3.component.ui.editor.fx.visual.ContentComponentPortVisual;
import org.fortiss.af3.component.ui.editor.fx.visual.ContentComponentVisual;
import org.fortiss.af3.component.ui.editor.fx.visual.DiagramComponentPortVisual;
import org.fortiss.tooling.base.ui.editor.fx.visual.NamedLayoutedLineLinkVisual;
/**
* The implementation of the {@link IVisualFactory} for the component editor.
......@@ -76,7 +76,7 @@ public final class ComponentVisualFactory implements IVisualFactory {
public ILinkVisual createLinkVisual(ILinkMVCBundle modelBundle) {
Object linkObj = modelBundle.getModel();
if(linkObj instanceof Channel) {
return new NamedLayoutedLineLinkVisual<>(modelBundle, Channel.class);
return new ChannelVisual(modelBundle);
}
return null;
}
......
ChannelVisual.java 3cdee0047f9ee3f9414488551d471b2e9f74ad67 GREEN
ContentComponentPortVisual.java 6e398120650316a0649173efd70c508efd3b5d09 GREEN
ContentComponentVisual.java 1343052af19542e4860043c0bcfb2b3e997d0422 GREEN
ContentComponentVisual.java 78fb7e6210f1d3fc37b869c18b11f37e73daec04 GREEN
DiagramComponentPortVisual.java 918915c5801064ebfb2bb6028f4e588256b1aefe GREEN
/*-------------------------------------------------------------------------+
| Copyright 2020 fortiss GmbH |
| |
| Licensed under the Apache License, Version 2.0 (the "License"); |
| you may not use this file except in compliance with the License. |
| You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, software |
| distributed under the License is distributed on an "AS IS" BASIS, |
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions and |
| limitations under the License. |
+--------------------------------------------------------------------------*/
package org.fortiss.af3.component.ui.editor.fx.visual;
import static javafx.scene.control.Tooltip.install;
import static org.fortiss.tooling.common.ui.javafx.util.GraphicUtils.getFXImage;
import java.util.Collection;
import org.eclipse.emf.ecore.EObject;
import org.fortiss.af3.component.model.Channel;
import org.fortiss.tooling.base.ui.editor.fx.visual.NamedLayoutedLineLinkVisual;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramCoordinate;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramLayers;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.ILinkMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.IVisual;
import org.fortiss.tooling.kernel.extension.data.IConstraintViolation;
import org.fortiss.tooling.kernel.extension.data.IConstraintViolation.ESeverity;
import org.fortiss.tooling.kernel.ui.ToolingKernelUIActivator;
import org.fortiss.tooling.kernel.ui.service.IMarkerService;
import javafx.scene.control.Label;
import javafx.scene.control.Tooltip;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
/**
* {@link IVisual} for {@link Channel}.
*
* @author hoelzl
*/
public class ChannelVisual extends NamedLayoutedLineLinkVisual<Channel> {
/** The label to show errors/warnings. */
private Label errorWarning = null;
/** Constructor. */
public ChannelVisual(ILinkMVCBundle mvcb) {
super(mvcb, Channel.class);
}
/** {@inheritDoc} */
@Override
public void updateNodes(DiagramLayers layers) {
super.updateNodes(layers);
if(errorWarning != null) {
layers.getVisualFeedbackLayer().remove(errorWarning);
errorWarning = null;
}
IMarkerService markerService = IMarkerService.getInstance();
Channel modelElement = getModelElement();
ESeverity highest = markerService.getHighestViolationSeverity(modelElement);
if(highest == null) {
return;
}
if(highest != ESeverity.ERROR && highest != ESeverity.WARNING) {
return;
}
Collection<IConstraintViolation<? extends EObject>> violations =
markerService.getAllViolationsWithSeverity(highest);
if(violations.isEmpty()) { // sanity check: never true, since highest != null
return;
}
String imgFile = (highest == ESeverity.WARNING) ? "warning.png" : "error.png";
Image img = getFXImage(ToolingKernelUIActivator.PLUGIN_ID, "icons/" + imgFile);
errorWarning = new Label("");
errorWarning.setGraphic(new ImageView(img));
DiagramCoordinate sp = getStartAnchorPoint();
DiagramCoordinate ep = getEndAnchorPoint();
if(getNumberOfBendPoints() > 0) {
ep = getBendPointLocation(0);
}
double x = sp.getX() + (ep.getX() - sp.getX()) / 2;
double y = sp.getY() + (ep.getY() - sp.getY()) / 2 - img.getHeight();
errorWarning.setTranslateX(x);
errorWarning.setTranslateY(y);
layers.getVisualFeedbackLayer().add(errorWarning, getMVCBundle());
// unset mouse listeners to make tooltip work
errorWarning.setOnMouseEntered(null);
errorWarning.setOnMouseExited(null);
Tooltip tooltip = new Tooltip(violations.iterator().next().getExplanation());
tooltip.setGraphic(new ImageView(img));
install(errorWarning, tooltip);
}
}
......@@ -15,19 +15,31 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.component.ui.editor.fx.visual;
import static javafx.scene.control.Tooltip.install;
import static javafx.scene.control.Tooltip.uninstall;
import static org.fortiss.af3.component.ui.DefaultStyle.STRONGLY_CAUSAL_COMPONENT_BACKGROUND;
import static org.fortiss.af3.component.ui.DefaultStyle.SUBSTRUCTURE_COMPONENT_BACKGROUND;
import static org.fortiss.af3.component.ui.DefaultStyle.WEAKLY_CAUSAL_COMPONENT_BACKGROUND;
import static org.fortiss.tooling.common.ui.javafx.util.GraphicUtils.convertColor;
import static org.fortiss.tooling.common.ui.javafx.util.GraphicUtils.getFXImage;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.IContentVisual;
import java.util.Collection;
import org.eclipse.emf.ecore.EObject;
import org.fortiss.af3.component.model.Component;
import org.fortiss.af3.component.ui.AF3ComponentUIActivator;
import org.fortiss.tooling.base.ui.editor.fx.visual.NamedLayoutedRectangularContentVisual;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramLayers;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.visual.IContentVisual;
import org.fortiss.tooling.kernel.extension.data.IConstraintViolation;
import org.fortiss.tooling.kernel.extension.data.IConstraintViolation.ESeverity;
import org.fortiss.tooling.kernel.ui.ToolingKernelUIActivator;
import org.fortiss.tooling.kernel.ui.service.IMarkerService;
import javafx.scene.control.Tooltip;
import javafx.scene.image.Image;
import javafx.scene.image.ImageView;
import javafx.scene.paint.Color;
import javafx.scene.paint.Paint;
......@@ -53,11 +65,44 @@ public final class ContentComponentVisual extends NamedLayoutedRectangularConten
private static final Color WEAKLY_CAUSAL_COLOR =
convertColor(WEAKLY_CAUSAL_COMPONENT_BACKGROUND);
/** Stores the last tooltip for uninstalling */
private Tooltip tooltip;
/** Constructor. */
public ContentComponentVisual(IContentMVCBundle mvcb) {
super(mvcb, Component.class);
}
/** {@inheritDoc} */
@Override
public void updateNodes(DiagramLayers layers) {
super.updateNodes(layers);
IMarkerService markerService = IMarkerService.getInstance();
ESeverity highest = markerService.getHighestViolationSeverity(getModelElement());
if(tooltip != null) {
uninstall(getHitAreaRectangleShape(), tooltip);
}
if(highest == null) {
return;
}
if(highest == ESeverity.WARNING || highest == ESeverity.ERROR) {
Collection<IConstraintViolation<? extends EObject>> violations =
markerService.getAllViolationsWithSeverity(highest);
if(violations.isEmpty()) { // sanity check: never true, since highest != null
return;
}
String imgFile = (highest == ESeverity.WARNING) ? "warning.png" : "error.png";
Image img = getFXImage(ToolingKernelUIActivator.PLUGIN_ID, "icons/" + imgFile);
icon.setImage(img);
String explanation = violations.iterator().next().getExplanation();
tooltip = new Tooltip(explanation);
tooltip.setGraphic(new ImageView(img));
install(getHitAreaRectangleShape(), tooltip);
}
}
/** {@inheritDoc} */
@Override
protected Paint getFillColor() {
......
ComponentSpecificationPropertySection.java fb5b6d82090f7ae063a8876b421529075d072939 GREEN
PortDataPropagation.java 9305d9fd7bb52398bdf227ddf7e1b54adac15808 GREEN
PortInitValueSection.java c25ad3fd1998f35c10a541caad3211f1333ae420 GREEN
PortSpecificationPropertySection.java 180ea52f0c50c4fd3d3ee2a7e59d22d0e3e05c75 RED
PortSpecificationPropertySection.java 051d483d1ff4300fc4920de0f2a76eb12ee29fcc RED
TypeLabelProvider.java 5b0fcced122681125f7df55469ea19b3685eb8bd GREEN
......@@ -16,7 +16,6 @@
package org.fortiss.af3.component.ui.properties;
import static org.fortiss.af3.component.AF3ComponentActivator.getDefault;
import static org.fortiss.af3.component.ui.properties.PortDataPropagation.getPortsToPropagate;
import static org.fortiss.af3.component.utils.ComponentArchitectureUtils.hasReadOnlyBehaviorSpecification;
import static org.fortiss.af3.expression.utils.ExpressionUtils.getAllVisibleTypes;
import static org.fortiss.tooling.kernel.utils.EcoreUtils.copy;
......@@ -27,7 +26,6 @@ import java.util.List;
import java.util.function.Consumer;
import java.util.stream.Collectors;
import org.conqat.lib.commons.collections.Pair;
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.jface.layout.GridDataFactory;
......@@ -236,9 +234,6 @@ public final class PortSpecificationPropertySection extends PropertySectionBase
IType selectedType = (IType)selection.getFirstElement();
if(!typesAreEqual(selectedType, spec.getType())) {
spec.setType(copy(selectedType));
for(Pair<Channel, Port> c : getPortsToPropagate(port, getPart())) {
c.getSecond().getPortSpecification().setType(copy(selectedType));
}
}
refreshBoundsControls();
......
component.ecore 6487189a39ecf7d7475e92431b3fa5b5e5dc813e GREEN
component.ecore a7528518daf70c14db0076c8311fa66f9a250458 GREEN
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="model" nsURI="http://www.fortiss.org/af3/component" nsPrefix="org-fortiss-af3-component">
<eClassifiers xsi:type="ecore:EClass" name="ComponentArchitecture" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//IProjectRootElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/IFunctionScope platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/ITypeScope platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained">
<eClassifiers xsi:type="ecore:EClass" name="ComponentArchitecture" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//IProjectRootElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/IFunctionScope platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/ITypeScope">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="This is the root element of the component architecture."/>
</eAnnotations>
......@@ -45,7 +45,7 @@
<eParameters name="name" lowerBound="1" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
</eOperations>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="Component" eSuperTypes="platform:/resource/org.fortiss.tooling.base/model/base.ecore#//base/HierarchicElementBase platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/IVariableScope platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//ISpeciallyCopyiable platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained platform:/resource/org.fortiss.af3.project/model/project.ecore#//ITraceableArtifact">
<eClassifiers xsi:type="ecore:EClass" name="Component" eSuperTypes="platform:/resource/org.fortiss.tooling.base/model/base.ecore#//base/HierarchicElementBase platform:/resource/org.fortiss.af3.project/model/project.ecore#//typesystem/IVariableScope platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//ISpeciallyCopyiable platform:/resource/org.fortiss.af3.project/model/project.ecore#//ITraceableArtifact">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="documentation" value="This is the main concept to encapsulate behaviors. A component can be atomic - implementing a behavior by means of code specification or state automaton specification, or hierarchical - containing subcomponents with behaviors. "/>
</eAnnotations>
......
......@@ -5,7 +5,7 @@ ComponentLibraryModelElementFactory.java b6c854e91d431fa3bc42fafdcf618a2040d23ab
ComponentLibraryUtils.java dd5fb918e37c98c885b59ea1a7915b8cdf149997 GREEN
ComponentModelElementFactory.java 7d73764f4ebc3a45bcd2833c68a06213109784a0 GREEN
ComponentProgramUtils.java 71faad6256159ee2d59843fcde83ac6995dff0fe GREEN
ComponentUtils.java d4aa3db08fafafaa937b976c85762f1009fa8dc7 GREEN
ComponentUtils.java e2ae1c22731f28dfcb6ddfde1518974d819e20f1 GREEN
GeneratorModelElementFactory.java 7fdb75341336fe579d4338a53c99df2f091c2b09 GREEN
IComponentArchitectureTransformation.java da70307771248f1d95e2fcd68e86fd68327f9df0 GREEN
SimulationUtils.java a28590d89ed92d862bf7b657b9dfc4784545e36a GREEN
......@@ -134,7 +134,6 @@ public class ComponentUtils {
/** Keeps only the behavioral specification of the component. */
public static void removeNonBehavior(Component comp) {
comp.getConstraintInstances().clear();
removeSpecs(comp, spec -> spec instanceof IComponentBehaviorDefinitionSpecification);
}
......
mira.ecore 6f65a501f30154def7b0805517153fb4f5516b9c RED
mira.ecore 145ac5dedefbfde9c9cf288eb10cf85e670e1ed9 GREEN
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="model" nsURI="http://www.fortiss.org/af3/mira" nsPrefix="org-fortiss-af3-mira">
<eClassifiers xsi:type="ecore:EClass" name="Analysis" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//IProjectRootElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained">
<eClassifiers xsi:type="ecore:EClass" name="Analysis" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//IProjectRootElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement">
<eOperations name="getRequirementsList">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="return AnalysisStaticImpl.getRequirementsList(this);"/>
......@@ -32,7 +32,7 @@
</eAnnotations>
</eOperations>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="Requirement" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement #//IImageContainer platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained">
<eClassifiers xsi:type="ecore:EClass" name="Requirement" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement #//IImageContainer">
<eOperations name="getAnalysis" eType="#//Analysis">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="return RequirementStaticImpl.getAnalysis(this);"/>
......@@ -127,7 +127,7 @@
</eOperations>
<eStructuralFeatures xsi:type="ecore:EAttribute" name="text" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="RequirementsPackage" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained">
<eClassifiers xsi:type="ecore:EClass" name="RequirementsPackage" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement">
<eOperations name="getRequirementsList">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="return RequirementsPackageStaticImpl.getRequirementsList(this);"/>
......@@ -150,7 +150,7 @@
</eGenericType>
</eOperations>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="RequirementsContainer" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained">
<eClassifiers xsi:type="ecore:EClass" name="RequirementsContainer" eSuperTypes="platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//INamedCommentedElement platform:/resource/org.fortiss.tooling.base/model/base.ecore#//element/IHierarchicElement">
<eOperations name="getRequirementsPackagesList">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="return RequirementsContainerStaticImpl.getRequirementsPackagesList(this);"/>
......
ModeAutomatonControllerFactory.java 3e60fb8432aef914d0c63e8dfeb18b6ac57ddb6f GREEN
ModeAutomatonFXEditor.java 2d70d6f9ad225ebb767d20009f3d7f9f9dda2be2 GREEN
ModeAutomatonControllerFactory.java aa768159a389d90522b275e4481fb2db78669a25 GREEN
ModeAutomatonFXEditor.java 0e772da01045f7dc39c1005735c47e51d8b92a5b GREEN
ModeAutomatonFXEditorBinding.java d3503a20fc9fccc6a8805674bdabaa2135fd28c2 GREEN
ModeAutomatonModelFactory.java 90826e0ff88b73784e41cc71f473c11daa6bc36d GREEN
ModeAutomatonVisualFactory.java a9b82127b572bf9533474bcf22168e79922b2f16 GREEN
......
......@@ -15,22 +15,22 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.mode.ui.editor.fx;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IController;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IControllerFactory;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.ILinkMVCBundle;
import org.fortiss.af3.mode.model.Mode;
import org.fortiss.af3.mode.model.ModeAutomaton;
import org.fortiss.af3.mode.model.SwitchSegment;
import org.fortiss.af3.mode.model.SwitchSegmentConnector;
import org.fortiss.tooling.base.ui.editor.fx.controller.CurvedLinkLayoutedContentAnchorangeController;
import org.fortiss.tooling.base.ui.editor.fx.controller.CurvedLinkLayoutedDiagramAnchorangeController;
import org.fortiss.tooling.base.ui.editor.fx.controller.EObjectDiagramController;
import org.fortiss.tooling.base.ui.editor.fx.controller.LayoutedCurveLinkBendPointController;
import org.fortiss.tooling.base.ui.editor.fx.controller.LayoutedDiagramAnchorageController;
import org.fortiss.tooling.base.ui.editor.fx.controller.LayoutedEllipticResizableContentController;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IController;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IControllerFactory;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.ILinkMVCBundle;
/**
* Implementation of the {@link IControllerFactory} for the {@link ModeAutomaton} editor.
......@@ -41,33 +41,32 @@ public class ModeAutomatonControllerFactory implements IControllerFactory {
/** {@inheritDoc} */
@Override
public IController createContentController(IContentMVCBundle model) {
return new LayoutedEllipticResizableContentController<Mode>(model, Mode.class);
return new LayoutedEllipticResizableContentController<>(model, Mode.class);
}
/** {@inheritDoc} */
@Override
public IController createDiagramAnchorageController(IDiagramAnchorageMVCBundle modelBundle) {
return new LayoutedDiagramAnchorageController<SwitchSegmentConnector>(modelBundle,
return new CurvedLinkLayoutedDiagramAnchorangeController<>(modelBundle,
SwitchSegmentConnector.class);
}
/** {@inheritDoc} */
@Override
public IController createContentAnchorageController(IContentAnchorageMVCBundle modelBundle) {
return new CurvedLinkLayoutedContentAnchorangeController<SwitchSegmentConnector>(
modelBundle, SwitchSegmentConnector.class);
return new CurvedLinkLayoutedContentAnchorangeController<>(modelBundle,
SwitchSegmentConnector.class);
}
/** {@inheritDoc} */
@Override
public IController createLinkController(ILinkMVCBundle modelBundle) {
return new LayoutedCurveLinkBendPointController<SwitchSegment>(modelBundle,
SwitchSegment.class);
return new LayoutedCurveLinkBendPointController<>(modelBundle, SwitchSegment.class);
}
/** {@inheritDoc} */
@Override
public IController createDiagramController(IDiagramMVCBundle diagramBundle) {
return new EObjectDiagramController<Mode>(diagramBundle, Mode.class);
return new EObjectDiagramController<>(diagramBundle, Mode.class);
}
}
......@@ -18,12 +18,12 @@ package org.fortiss.af3.mode.ui.editor.fx;
import static javafx.scene.paint.Color.LIGHTGRAY;
import org.eclipse.emf.ecore.EObject;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramViewerFeatures;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramViewerFeatures.IndicatorType;
import org.fortiss.af3.mode.model.Mode;
import org.fortiss.af3.mode.model.ModeAutomaton;
import org.fortiss.af3.mode.model.SwitchSegment;
import org.fortiss.af3.mode.model.SwitchSegmentConnector;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramViewerFeatures;
import org.fortiss.tooling.common.ui.javafx.lwfxef.DiagramViewerFeatures.IndicatorType;
import org.fortiss.tooling.kernel.ui.extension.base.LWFXEFEditorBase;
/**
......
HierarchicPlatformArchitectureCompositor.java fecefdbd64c391f179730ac5aea7e7265ec81fca GREEN
HierarchicalCompositionRules.java 711685d75d9817ec37156dc087d997c119e4c561 GREEN
HierarchicalCompositionRules.java 70651bf28c1a455eead6556e7578c81317aa9d5c GREEN
......@@ -76,6 +76,7 @@ public class HierarchicalCompositionRules extends PlatformHierarchicalCompositio
rval.add(IOffChipNetworkDomain.class);
rval.add(IMemoryDomain.class);
rval.add(IElectronicsDomain.class);
rval.add(IPeripheralsDomain.class);
} else if(hasEqualLevel(domain, ITileDomain.class)) {
// Required for availability of these elements at the tile level (i.e., to drop elements
// from the processor / NoC domain into tile domain elements.)
......
......@@ -5,12 +5,12 @@ CoreCompositor.java 050798a2f694a04c23595ab7b9dee9756e9a3404 GREEN
MemoryCompositor.java 3064bb9b47a0df16eb85304481716d56273a21b9 GREEN
NetworkInterfaceCompositor.java da20db4c57e17921143fd8ea87635d9f341904b5 GREEN
NocRouterCompositor.java 3180a7cc98c6335f3fdc70befbdd5367e924e3d2 GREEN
NodeCompositor.java 02f6556b04c58a481c698a161e7a2607be30c2f8 GREEN
NodeCompositor.java 096dee7cba39dec1c767ebfc68cc13dbded7fa56 GREEN
OffChipNetworkCompositor.java 7eae93d5e917837891bfdd624fede77fd762858d GREEN
OffChipNetworkGatewayCompositor.java 9aed7241e987c5bb525886840fed9604dd78ede0 GREEN
OffChipNetworkRouterCompositor.java b7893fbbc0865f98d63c4ac7c647f5efba3b7b28 GREEN
OnChipNetworkCompositor.java b90a297b0efdeb97b4b06c2bd0e22ad7737df588 GREEN
OnChipOffChipGatewayCompositor.java e9f51bc859ec7901c8f9fa1b1751c2a5804d6b3c GREEN
PowerSupplyCompositor.java 1a3f76d53557533d80c7ffdb8c28500bd453ff47 GREEN
TileCompositor.java 2b59f673831d5d6a2065db8903b2bf8c06f0c1e8 GREEN
TileCompositor.java ebeed4a6bfcddf498379e5a05d1bc33d3a633afa GREEN
WatchDogCompositor.java 9d121bde08bc3e68c91ab53c673bd8865ae6fc44 GREEN
......@@ -24,6 +24,7 @@ import org.fortiss.af3.platform.hierarchic.model.electronics.PowerIn;
import org.fortiss.af3.platform.hierarchic.model.node.Node;
import org.fortiss.af3.platform.hierarchic.model.peripherals.GeneralPurposeInput;
import org.fortiss.af3.platform.hierarchic.model.peripherals.GeneralPurposeOutput;
import org.fortiss.af3.platform.hierarchic.model.peripherals.WatchDog;
import org.fortiss.af3.platform.hierarchic.model.tile.OnChipNetwork;
import org.fortiss.af3.platform.hierarchic.model.tile.Tile;
import org.fortiss.af3.platform.model.IArchitectureDomain;
......@@ -51,7 +52,7 @@ public final class NodeCompositor extends ExecutionUnitComponentCompositorBase<N
@Override
protected boolean canBeAddedAtCurrentLevel(IArchitectureDomain element) {
return super.canBeAddedAtCurrentLevel(element) ||
isInstanceOfAny(element, Tile.class, OnChipNetwork.class, PowerIn.class,
GeneralPurposeInput.class, GeneralPurposeOutput.class);
isInstanceOfAny(element, WatchDog.class, Tile.class, OnChipNetwork.class,
PowerIn.class, GeneralPurposeInput.class, GeneralPurposeOutput.class);
}
}
......@@ -23,7 +23,6 @@ import org.fortiss.af3.platform.hierarchic.compose.base.elements.ExecutionUnitCo
import org.fortiss.af3.platform.hierarchic.model.peripherals.GeneralPurposeInput;
import org.fortiss.af3.platform.hierarchic.model.peripherals.GeneralPurposeOutput;
import org.fortiss.af3.platform.hierarchic.model.peripherals.WatchDogIn;
import org.fortiss.af3.platform.hierarchic.model.tile.OnChipOffChipExport;
import org.fortiss.af3.platform.hierarchic.model.tile.Tile;
import org.fortiss.af3.platform.model.IArchitectureDomain;
......@@ -49,8 +48,7 @@ public final class TileCompositor extends ExecutionUnitComponentCompositorBase<T
/** {@inheritDoc} */
@Override
protected boolean canBeAddedAtCurrentLevel(IArchitectureDomain element) {
return isInstanceOfAny(element, OnChipOffChipExport.class, WatchDogIn.class,
GeneralPurposeInput.class, GeneralPurposeOutput.class) ||
super.canBeAddedAtCurrentLevel(element);
return isInstanceOfAny(element, WatchDogIn.class, GeneralPurposeInput.class,
GeneralPurposeOutput.class) || super.canBeAddedAtCurrentLevel(element);
}
}
......@@ -6,7 +6,7 @@ DeleteOutputPortReference.java f4e0b20d1671d6675780b3a37647bb6868d03775 GREEN
DeleteReference.java 348af1127eb54397a68642c71cf5515879333a4f GREEN
DeleteRequirementReference.java d8918d7b8a059b5bf9ff093ec8a55f16c9e6fdf6 GREEN
GenerateModuleConnections.java f07409c4f9276d9359991ec4cd0ddaaed76839dd GREEN
GoToReferencedAF3Element.java a045feb80e8caa131fb5520dfb8d3dbbabe7a89f GREEN
GoToReferencedAF3Element.java 640c31613dfa07f0017db1d7fe35dd01bef99676 GREEN
GoToReferencedComponentInputPorts.java 82d4ac5b6b589a45dcabf1496ebe89d2031593de GREEN
GoToReferencedComponentOutputPorts.java d4c80efe328159b47aafafa525d6c7391d384bee GREEN
GoToReferencedContext.java 158f24ccf9e520c2e33e91d1ceacab1beaacb006 GREEN
......
......@@ -28,7 +28,6 @@ import org.eclipse.jface.action.ActionContributionItem;
import org.eclipse.jface.action.IContributionItem;
import org.fortiss.af3.safetycases.model.ArgumentElement;
import org.fortiss.af3.safetycases.ui.AF3SafetyCasesUIActivator;
import org.fortiss.tooling.kernel.model.constraints.ConstraintInstance;
import org.fortiss.tooling.kernel.ui.extension.IContextMenuContributor;
import org.fortiss.tooling.kernel.ui.extension.data.ContextMenuContextProvider;
......@@ -76,8 +75,7 @@ public class GoToReferencedAF3Element implements IContextMenuContributor {
/** {@inheritDoc} */
@Override
public void run() {
if(selected.getAf3Element() != null &&
!(selected.getAf3Element() instanceof ConstraintInstance)) {
if(selected.getAf3Element() != null) {
getInstance().openInEditor(selected.getAf3Element());
}
}
......
requirementspatterns.ecore b2f09bfc949bafb0392929115b3c0321bf2b192c RED
safetyargumentationpackage.ecore e95d1c0c64d12fa1660899df86cc9009dbae1754 RED
safetycases.ecore b3b1dcf0f18facde3ebb68f29c4300b4e7bcf349 RED
safetycases.ecore f00dffa5abfeb387c709853c5bdea4e78ca05165 GREEN
......@@ -51,7 +51,7 @@
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="EntryConnector" eSuperTypes="#//SafetyCasesConnector platform:/resource/org.fortiss.tooling.base/model/base.ecore#//base/EntryConnectorBase"/>
<eClassifiers xsi:type="ecore:EClass" name="ExitConnector" eSuperTypes="#//SafetyCasesConnector platform:/resource/org.fortiss.tooling.base/model/base.ecore#//base/ExitConnectorBase"/>
<eClassifiers xsi:type="ecore:EClass" name="ArgumentElementBase" eSuperTypes="platform:/resource/org.fortiss.tooling.base/model/base.ecore#//base/HierarchicElementBase platform:/resource/org.fortiss.tooling.kernel/model/kernel.ecore#//constraints/IConstrained">
<eClassifiers xsi:type="ecore:EClass" name="ArgumentElementBase" eSuperTypes="platform:/resource/org.fortiss.tooling.base/model/base.ecore#//base/HierarchicElementBase">
<eOperations name="getEntryConnectors" upperBound="-1" eType="#//EntryConnector">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="return org.fortiss.tooling.kernel.utils.EcoreUtils.pickInstanceOf(&#xD;&#xA;&#x9;&#x9;&#x9;&#x9;EntryConnector.class, getConnectors());"/>
......
......@@ -3,9 +3,9 @@ DataStateFXEditorBase.java 0bec3533962ebcd7326f6597d598a5ff7c8ba8e6 GREEN
DataStateFXEditorBinding.java 46ab36b197a6fca102a5e2d75aa24b1fbba26b89 GREEN
DataStateFXEditorContentProvider.java 324cd24e2219ba2cf360b0f82e3628ca1b5dabba GREEN
DataStateFXEditorUIProvider.java 4993d4a6685b7738dd28a7a55177ab43fe81fc53 GREEN
StateAutomatonControllerFactory.java 03d624ad560508280c01898da29eac0450bbb237 GREEN
StateAutomatonControllerFactory.java 67f7f7bbc318018080a4569d84e0f1830ce33bda GREEN
StateAutomatonFXEditor.java eea88e496c873ec92f6b2a0735cbd3d542a3063f GREEN
StateAutomatonFXEditorBase.java 788601b7fa8ba9bb9ca0b5d946d78ec4db220fbe GREEN
StateAutomatonFXEditorBase.java 901e1ce52a2a53fb73c160b0af7fd7fbfc1e3044 GREEN
StateAutomatonFXEditorBinding.java 5fae7a8e04236c07d176a2b1ed22f7043e3a09fe GREEN
StateAutomatonFXEditorBindingBase.java c2bf20b1e1d709a9c7662a62795662f8fc33b855 GREEN
StateAutomatonModelFactory.java 07989fa95608fc8ce25e977cba898cf94932e0ae GREEN
......
......@@ -15,22 +15,22 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.state.ui.editor.fx;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IController;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IControllerFactory;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.ILinkMVCBundle;
import org.fortiss.af3.state.model.State;
import org.fortiss.af3.state.model.StateAutomaton;
import org.fortiss.af3.state.model.TransitionSegment;
import org.fortiss.af3.state.model.TransitionSegmentConnector;
import org.fortiss.tooling.base.ui.editor.fx.controller.CurvedLinkLayoutedContentAnchorangeController;
import org.fortiss.tooling.base.ui.editor.fx.controller.CurvedLinkLayoutedDiagramAnchorangeController;
import org.fortiss.tooling.base.ui.editor.fx.controller.EObjectDiagramController;
import org.fortiss.tooling.base.ui.editor.fx.controller.LayoutedCurveLinkBendPointController;
import org.fortiss.tooling.base.ui.editor.fx.controller.LayoutedDiagramAnchorageController;
import org.fortiss.tooling.base.ui.editor.fx.controller.LayoutedEllipticResizableContentController;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IController;
import org.fortiss.tooling.common.ui.javafx.lwfxef.controller.IControllerFactory;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IContentMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramAnchorageMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.IDiagramMVCBundle;
import org.fortiss.tooling.common.ui.javafx.lwfxef.mvc.ILinkMVCBundle;
/**
* The implementation of the {@link IControllerFactory} for a {@link StateAutomaton}.
......@@ -41,21 +41,21 @@ public class StateAutomatonControllerFactory implements IControllerFactory {
/** {@inheritDoc} */
@Override
public IController createContentController(IContentMVCBundle model) {
return new LayoutedEllipticResizableContentController<State>(model, State.class);
return new LayoutedEllipticResizableContentController<>(model, State.class);
}