Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCamille Letavernier2014-08-21 11:37:18 +0000
committerCamille Letavernier2014-08-21 11:37:18 +0000
commitea48a20561464c3cbb7895d430583669a9f82fcc (patch)
tree0fdf9eebacbbb301b13bafce3ca4a6952ff6e91c /extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types
parentf91b71175fd97557cf378cdcad845a44a6274b16 (diff)
downloadorg.eclipse.papyrus-ea48a20561464c3cbb7895d430583669a9f82fcc.tar.gz
org.eclipse.papyrus-ea48a20561464c3cbb7895d430583669a9f82fcc.tar.xz
org.eclipse.papyrus-ea48a20561464c3cbb7895d430583669a9f82fcc.zip
[Code style] Apply clean-up and formatter on Extra plug-ins
Diffstat (limited to 'extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types')
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/Activator.java6
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/elements/EastadlElementTypes.java6
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/filter/EastadlCommandFilter.java11
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/handlers/AbstractEastadlCreateCommandHandler.java2
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/helper/AllocateEditHelperAdvice.java7
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/matcher/AllocateMatcher.java7
-rw-r--r--extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/menu/AbstractCreateEastadlChildMenu.java2
7 files changed, 26 insertions, 15 deletions
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/Activator.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/Activator.java
index ba2dbb4bb3d..da09a05ec5a 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/Activator.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/Activator.java
@@ -13,7 +13,7 @@ public class Activator extends AbstractUIPlugin {
// The shared instance
private static Activator plugin;
-
+
/**
* The constructor
*/
@@ -22,8 +22,10 @@ public class Activator extends AbstractUIPlugin {
/*
* (non-Javadoc)
+ *
* @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
*/
+ @Override
public void start(BundleContext context) throws Exception {
super.start(context);
plugin = this;
@@ -31,8 +33,10 @@ public class Activator extends AbstractUIPlugin {
/*
* (non-Javadoc)
+ *
* @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
*/
+ @Override
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/elements/EastadlElementTypes.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/elements/EastadlElementTypes.java
index fda6739baa6..f1bc0e70518 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/elements/EastadlElementTypes.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/elements/EastadlElementTypes.java
@@ -3,11 +3,11 @@ package org.eclipse.papyrus.eastadl.service.types.elements;
import org.eclipse.gmf.runtime.emf.type.core.AbstractElementTypeEnumerator;
import org.eclipse.gmf.runtime.emf.type.core.IHintedType;
-public class EastadlElementTypes extends AbstractElementTypeEnumerator{
+public class EastadlElementTypes extends AbstractElementTypeEnumerator {
/** Constant for SysML nature */
public static final String SYSML_NATURE = "East-adl_Nature";
-
+
/** IElementType for SysML Allocate */
- public static final IHintedType FUNCTION_ALLOCATE = (IHintedType)getElementType("org.eclipse.papyrus.eastadl.structure.functionmodeling.FunctionAllocation"); //$NON-NLS-1$
+ public static final IHintedType FUNCTION_ALLOCATE = (IHintedType) getElementType("org.eclipse.papyrus.eastadl.structure.functionmodeling.FunctionAllocation"); //$NON-NLS-1$
}
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/filter/EastadlCommandFilter.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/filter/EastadlCommandFilter.java
index be17bb2ad2a..d933ee2ab94 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/filter/EastadlCommandFilter.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/filter/EastadlCommandFilter.java
@@ -12,21 +12,24 @@ import org.eclipse.papyrus.uml.service.types.filter.ICommandFilter;
public class EastadlCommandFilter implements ICommandFilter {
public static final EastadlCommandFilter INSTANCE = new EastadlCommandFilter();
+
private EastadlCommandFilter() {
-
+
}
+
private List<IElementType> visibleCommands;
+
@Override
public List<IElementType> getVisibleCommands() {
if (visibleCommands == null) {
List<IElementType> localVisibleCommands = new ArrayList<IElementType>();
localVisibleCommands = new ArrayList<IElementType>();
-
+
localVisibleCommands.add(EastadlElementTypes.FUNCTION_ALLOCATE);
-
+
localVisibleCommands.add(UMLElementTypes.PROPERTY);
-
+
this.visibleCommands = Collections.unmodifiableList(localVisibleCommands);
}
return visibleCommands;
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/handlers/AbstractEastadlCreateCommandHandler.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/handlers/AbstractEastadlCreateCommandHandler.java
index 5d29f8193f3..a8035cf5eda 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/handlers/AbstractEastadlCreateCommandHandler.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/handlers/AbstractEastadlCreateCommandHandler.java
@@ -8,6 +8,8 @@ public abstract class AbstractEastadlCreateCommandHandler extends
AbstractCreateCommandHandler {
private static final ICommandFilter filter = EastadlCommandFilter.INSTANCE;
+
+ @Override
public ICommandFilter getCommandFilter() {
return filter;
}
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/helper/AllocateEditHelperAdvice.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/helper/AllocateEditHelperAdvice.java
index 16e886365fe..e5dc0c487b3 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/helper/AllocateEditHelperAdvice.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/helper/AllocateEditHelperAdvice.java
@@ -13,7 +13,7 @@ import org.eclipse.papyrus.uml.service.types.utils.NamedElementHelper;
import org.eclipse.uml2.uml.NamedElement;
import org.eclipse.uml2.uml.util.UMLUtil.StereotypeApplicationHelper;
-public class AllocateEditHelperAdvice extends AbstractStereotypedElementEditHelperAdvice {
+public class AllocateEditHelperAdvice extends AbstractStereotypedElementEditHelperAdvice {
/** Default constructor */
public AllocateEditHelperAdvice() {
@@ -26,9 +26,10 @@ public class AllocateEditHelperAdvice extends AbstractStereotypedElementEditHel
return new ConfigureElementCommand(request) {
+ @Override
protected CommandResult doExecuteWithResult(IProgressMonitor progressMonitor, IAdaptable info) throws ExecutionException {
- NamedElement element = (NamedElement)request.getElementToConfigure();
- if(element != null) {
+ NamedElement element = (NamedElement) request.getElementToConfigure();
+ if (element != null) {
StereotypeApplicationHelper.INSTANCE.applyStereotype(element, FunctionmodelingPackage.eINSTANCE.getFunctionAllocation());
// Set default name
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/matcher/AllocateMatcher.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/matcher/AllocateMatcher.java
index fcf31bd268a..98992557193 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/matcher/AllocateMatcher.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/matcher/AllocateMatcher.java
@@ -8,13 +8,14 @@ import org.eclipse.uml2.uml.util.UMLUtil;
public class AllocateMatcher implements IElementMatcher {
+ @Override
public boolean matches(EObject eObject) {
boolean isMatch = false;
- if(eObject instanceof Abstraction) {
+ if (eObject instanceof Abstraction) {
- Abstraction element = (Abstraction)eObject;
- if(UMLUtil.getStereotypeApplication(element, FunctionAllocation.class) != null) {
+ Abstraction element = (Abstraction) eObject;
+ if (UMLUtil.getStereotypeApplication(element, FunctionAllocation.class) != null) {
isMatch = true;
}
}
diff --git a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/menu/AbstractCreateEastadlChildMenu.java b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/menu/AbstractCreateEastadlChildMenu.java
index 0e504a65251..8a8ee4ed2d9 100644
--- a/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/menu/AbstractCreateEastadlChildMenu.java
+++ b/extraplugins/eastadl/org.eclipse.papyrus.eastadl.service.types/src/org/eclipse/papyrus/eastadl/service/types/menu/AbstractCreateEastadlChildMenu.java
@@ -9,7 +9,7 @@ public class AbstractCreateEastadlChildMenu extends AbstractCreateMenuFromComman
/**
* Constructor.
- *
+ *
*/
public AbstractCreateEastadlChildMenu() {
super(SYSML_CREATION_COMMAND_CATEGORY);

Back to the top