Commit 76949e8f authored by Sudeep Kanav's avatar Sudeep Kanav
Browse files

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

parents bc91034c e2be998b
......@@ -7,6 +7,15 @@
<modelElementHandler handler="org.fortiss.af3.allocation.ui.handler.AllocationTableCollectionHandler">
<modelElementClass modelElementClass="org.fortiss.af3.allocation.model.AllocationTableCollection"/>
</modelElementHandler>
<modelElementHandler handler="org.fortiss.af3.allocation.ui.handler.ManyToOneAllocationEntryHandler">
<modelElementClass modelElementClass="org.fortiss.af3.allocation.model.ManyToOneAllocationEntry"/>
</modelElementHandler>
<modelElementHandler handler="org.fortiss.af3.allocation.ui.handler.OneToOneAllocationEntryHandler">
<modelElementClass modelElementClass="org.fortiss.af3.allocation.model.OneToOneAllocationEntry"/>
</modelElementHandler>
<modelElementHandler handler="org.fortiss.af3.allocation.ui.handler.OneToManyAllocationEntryHandler">
<modelElementClass modelElementClass="org.fortiss.af3.allocation.model.OneToManyAllocationEntry"/>
</modelElementHandler>
</extension>
<extension point="org.fortiss.tooling.kernel.modelPrototypeProvider">
......
AF3AllocationUIActivator.java d0d2f939b1c8a1ba0995a3dc6dfd2c197ab09832 GREEN
DefaultStyle.java 1981ac9801c7867c08868dde009415db4c5c8ba8 GREEN
ParameterEntryTreeViewerEditingSupport.java aedc9b5729911b42bf752d7edbe507ff4f447420 GREEN
ParameterEntryTreeViewerLabelProvider.java dacadca1f62afba95d0d6a68f7aca6252b34b172 GREEN
ParameterEntryTreeViewerLabelProvider.java 79c70864ef80404e31aa48f75d36072f35380762 GREEN
ParameterSourceElementTreeViewerEditingSupport.java 9e30e6e0df10beaaf3231c9ff06a0c5ab1df9b34 GREEN
ParameterSourceElementTreeViewerLabelProvider.java cb886708a180db20dee0411b37fa32185b9a95f5 GREEN
ParameterTableTreeViewerManager.java 33b2836459c8258127bd1174c938b5953b115eba GREEN
TreeViewerCheckBoxEditingSupport.java 00d09fbe4950453c0272c6b497b994ffeec38023 GREEN
TreeViewerCheckBoxLabelProvider.java 97fe6771fbe09ccd16c1fe1ade862d2f95093ed1 GREEN
TreeViewerCheckBoxLabelProvider.java 831580238a82f8b1fe87dc4ff8518efd9f42c25a GREEN
TreeViewerContentProvider.java e19b353b4f7624fd38db782524fed5cdf66dff55 GREEN
TreeViewerFirstColumnLabelProvider.java 41af5aeea1c94de2deb2a024b5d0c589302b0c15 GREEN
TreeViewerManager.java 2e073c418cfdf089f42d13be62ff3b26efca3a39 GREEN
TreeViewerManager.java ac9452a973bfcb14bda59c940155fb2343fdbe18 GREEN
......@@ -15,7 +15,7 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.allocation.ui.editor.treeviewer;
import static org.fortiss.af3.allocation.ui.DefaultStyle.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationUtils.getParameterEntryName;
import static org.fortiss.af3.allocation.utils.AllocationUtils.getParameterEntryValue;
......
......@@ -15,7 +15,7 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.allocation.ui.editor.treeviewer;
import static org.fortiss.af3.allocation.ui.DefaultStyle.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationUtils.isAllocated;
import static org.fortiss.af3.allocation.utils.AllocationUtils.isModifiableAllocationEntry;
......
......@@ -18,8 +18,8 @@ package org.fortiss.af3.allocation.ui.editor.treeviewer;
import static java.util.Arrays.sort;
import static java.util.Collections.emptyList;
import static org.eclipse.jface.viewers.AbstractTreeViewer.ALL_LEVELS;
import static org.fortiss.af3.allocation.ui.DefaultStyle.DOWN_ARROW;
import static org.fortiss.af3.allocation.ui.DefaultStyle.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.DOWN_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import java.util.ArrayList;
import java.util.Collection;
......
AllocationTableCollectionHandler.java d670d09ac29b35de7cdb12a9391f1c202b8dabe5 GREEN
ManyToOneAllocationEntryHandler.java 0f2b8ecaf7761b672d380b31558b3ca4a86eadce GREEN
OneToManyAllocationEntryHandler.java b8271e7603d4af63e0897b689f06ff9d2f2de28d GREEN
OneToOneAllocationEntryHandler.java 27a868c2b2cc528a119961990bb574ef35c4df51 GREEN
/*-------------------------------------------------------------------------+
| Copyright 2019 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.allocation.ui.handler;
import static java.util.stream.Collectors.joining;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import java.util.Collection;
import org.eclipse.jface.resource.ImageDescriptor;
import org.fortiss.af3.allocation.model.ManyToOneAllocationEntry;
import org.fortiss.tooling.base.model.element.IModelElement;
import org.fortiss.tooling.kernel.ui.extension.IModelElementHandler;
import org.fortiss.tooling.kernel.ui.extension.base.ModelElementHandlerBase;
import org.fortiss.tooling.kernel.ui.service.IModelElementHandlerService;
/**
* {@link IModelElementHandler} for {@link ManyToOneAllocationEntry}s.
*
* @author diewald
*/
public class ManyToOneAllocationEntryHandler
extends ModelElementHandlerBase<ManyToOneAllocationEntry> {
/** {@inheritDoc} */
@Override
public String getName(ManyToOneAllocationEntry element) {
IModelElementHandlerService handlerService = IModelElementHandlerService.getInstance();
Collection<IModelElement> sourceElements = element.getSourceElements();
String name = "[ " +
sourceElements.stream().map(e -> handlerService.getName(e)).collect(joining(",")) +
" ]";
name = name + " " + RIGHT_ARROW + " ";
name = name + handlerService.getName(element.getTargetElement());
return name;
}
/** {@inheritDoc} */
@Override
public ImageDescriptor getIconImageDescriptor() {
return null;
}
}
/*-------------------------------------------------------------------------+
| Copyright 2019 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.allocation.ui.handler;
import static java.util.stream.Collectors.joining;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import java.util.Collection;
import org.eclipse.jface.resource.ImageDescriptor;
import org.fortiss.af3.allocation.model.OneToManyAllocationEntry;
import org.fortiss.tooling.base.model.element.IModelElement;
import org.fortiss.tooling.kernel.ui.extension.IModelElementHandler;
import org.fortiss.tooling.kernel.ui.extension.base.ModelElementHandlerBase;
import org.fortiss.tooling.kernel.ui.service.IModelElementHandlerService;
/**
* {@link IModelElementHandler} for {@link OneToManyAllocationEntry}s.
*
* @author diewald
*/
public class OneToManyAllocationEntryHandler
extends ModelElementHandlerBase<OneToManyAllocationEntry> {
/** {@inheritDoc} */
@Override
public String getName(OneToManyAllocationEntry element) {
IModelElementHandlerService handlerService = IModelElementHandlerService.getInstance();
String name = handlerService.getName(element.getSourceElement());
name = name + " " + RIGHT_ARROW + " ";
Collection<IModelElement> targetElements = element.getTargetElements();
name = name + "[ " +
targetElements.stream().map(e -> handlerService.getName(e)).collect(joining(", "));
return name + " ]";
}
/** {@inheritDoc} */
@Override
public ImageDescriptor getIconImageDescriptor() {
return null;
}
}
/*-------------------------------------------------------------------------+
| Copyright 2017 fortiss GmbH |
| Copyright 2019 fortiss GmbH |
| |
| Licensed under the Apache License, Version 2.0 (the "License"); |
| you may not use this file except in compliance with the License. |
......@@ -13,18 +13,36 @@
| See the License for the specific language governing permissions and |
| limitations under the License. |
+--------------------------------------------------------------------------*/
package org.fortiss.af3.allocation.ui;
package org.fortiss.af3.allocation.ui.handler;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import org.eclipse.jface.resource.ImageDescriptor;
import org.fortiss.af3.allocation.model.OneToOneAllocationEntry;
import org.fortiss.tooling.kernel.ui.extension.IModelElementHandler;
import org.fortiss.tooling.kernel.ui.extension.base.ModelElementHandlerBase;
import org.fortiss.tooling.kernel.ui.service.IModelElementHandlerService;
/**
* Style definitions for allocation UI elments.
* {@link IModelElementHandler} for {@link OneToOneAllocationEntry}s.
*
* @author barner
* @author diewald
*/
public class DefaultStyle {
public class OneToOneAllocationEntryHandler
extends ModelElementHandlerBase<OneToOneAllocationEntry> {
/** Unicode right arrow. */
public static final String RIGHT_ARROW = "\u2192";
/** {@inheritDoc} */
@Override
public String getName(OneToOneAllocationEntry element) {
IModelElementHandlerService handlerService = IModelElementHandlerService.getInstance();
String sourceName = handlerService.getName(element.getSourceElement());
String targetName = handlerService.getName(element.getTargetElement());
return sourceName + " " + RIGHT_ARROW + " " + targetName;
}
/** Unicode down arrow. */
public static final String DOWN_ARROW = "\u2193";
/** {@inheritDoc} */
@Override
public ImageDescriptor getIconImageDescriptor() {
return null;
}
}
......@@ -2,5 +2,5 @@ AF3AllocationFactoryImplCustom.java 36f55f6cc9ab49c09223a7b0c0163157b137aeb3 GRE
AllocationEntryStaticImpl.java 49e2c1390029f9652e8d891a1ce281f30e941d5b GREEN
AllocationTableCollectionStaticImpl.java d1ebdc08e00373ca5940853c1fb7c1b0a5b19c43 GREEN
AllocationTableStaticImpl.java b4abaca7b71433d05bb0ec33ad6c619d96ad9f54 GREEN
ParameterEntryStaticImpl.java 45ff9e4ab15af6527f6cba27920954981697d23d GREEN
ParameterEntryStaticImpl.java 81f62de67eaeac99da628853f31ae13bc6a33cc4 GREEN
ParameterTableStaticImpl.java cbf046b336d70c0b7b9e5976eda99537a8f73114 GREEN
......@@ -15,6 +15,7 @@
+--------------------------------------------------------------------------*/
package org.fortiss.af3.allocation.model.impl;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import static org.fortiss.tooling.kernel.utils.KernelModelElementUtils.computeFullyQualifiedName;
import static org.fortiss.tooling.kernel.utils.KernelModelElementUtils.computeRelativeName;
......@@ -43,9 +44,6 @@ public class ParameterEntryStaticImpl {
return element != null ? element.toString() : "<null>";
}
/** Unicode right arrow. */
private static final String RIGHT_ARROW = "\u2192";
/**
* Computes the "name" of the given {@link ParameterEntry} based on its referenced
* {@code sourceElement} and {@code targetElement}.
......
AllocationModelElementFactory.java 1790fc35d560cdf74ac1900c0d289e58900a0c32 GREEN
AllocationModelElementFactory.java 9aba183708290c741ebbbe2897bbfcc51ea33fb6 GREEN
AllocationUtils.java c5d804fc26e9b2664af32e3eb3b9379dd10f9802 GREEN
......@@ -33,6 +33,12 @@ import org.fortiss.af3.allocation.model.OneToOneAllocationEntry;
*/
public class AllocationModelElementFactory {
/** Allocation Names: Unicode right arrow. */
public static final String RIGHT_ARROW = "\u2192";
/** Allocation Names: Unicode down arrow. */
public static final String DOWN_ARROW = "\u2193";
/**
* Creates a new {@link AllocationTableCollection}.
*
......
DeploymentValidatorStartMenu.java e52a4625c301441c2a62c225a55046a46e5d2155 RED
DeploymentValidatorStartMenu.java 8883f8a559fc53736a1b6c677e2c90a8daef3d5d RED
......@@ -18,7 +18,7 @@ package org.fortiss.af3.exploration.ui.menu;
import static java.util.Collections.emptyList;
import static org.conqat.ide.commons.ui.dialog.MessageUtils.showInfo;
import static org.conqat.ide.commons.ui.dialog.MessageUtils.showWarning;
import static org.fortiss.af3.allocation.ui.DefaultStyle.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import static org.fortiss.af3.project.utils.ProjectUtils.getFileProject;
import static org.fortiss.tooling.kernel.utils.EcoreUtils.getChildrenWithType;
......
ScheduleExporter.java 587a1fa783b4e0e0a16ae19369bedb7cf909d181 GREEN
TableComposite.java 59df3d0d637ce1c4f1306ec6e48a0da22d85a734 RED
TableVisualization.java 55ee4fdbf07a6a308d926ad407b22d082547be58 RED
TableVisualization.java db65ed9efef9dbcd96db768e909000e513b877e2 RED
......@@ -16,7 +16,7 @@
package org.fortiss.af3.exploration.ui.perspective.visualization.visualizations.table;
import static org.eclipse.emf.ecore.util.EcoreUtil.copyAll;
import static org.fortiss.af3.allocation.ui.DefaultStyle.RIGHT_ARROW;
import static org.fortiss.af3.allocation.utils.AllocationModelElementFactory.RIGHT_ARROW;
import static org.fortiss.af3.task.util.TaskModelElementFactory.createTasksToExecutionUnitAllocationTable;
import static org.fortiss.tooling.kernel.utils.UniqueIDUtils.fixMissingIDs;
......
......@@ -17,7 +17,8 @@ Require-Bundle: org.fortiss.af3.generator.common;bundle-version="2.14.0";visibil
org.fortiss.af3.project;visibility:=reexport,
org.fortiss.tooling.kernel;visibility:=reexport,
org.fortiss.tooling.base;visibility:=reexport,
org.fortiss.pragmatictransformation;bundle-version="2.14.0"
org.fortiss.pragmatictransformation;bundle-version="2.14.0",
com.microsoft.z3;bundle-version="2.14.0"
Export-Package: org.antlr.stringtemplate,
org.antlr.stringtemplate.language,
org.fortiss.af3.expression,
......
DataDictionaryUtils.java 67bd95a8f9eb89303b502f3831f228c85134f5bf GREEN
ExpressionModelElementFactory.java bb0dab610b1de6579292af12f07b99cf5d9d87ca GREEN
ExpressionUtils.java 02ee13866fa9eee9fed5bc5f31976ceaa71f1d77 GREEN
ExpressionUtils.java 9a07de5974cf670daecc83a7214a07206fd7e3fc GREEN
LibraryElementsFactory.java d0b803949097a7c840ced1d92c302ec4cef2054a GREEN
NoValSpecialTreatmentUtils.java 5d7736859de2bedc2ac5173e6090824f38acaf51 GREEN
OperatorStrengthUtils.java d876a3518cc01a8ab209f4b0d464fb4d030da96c GREEN
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment