Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrschnekenbu2013-08-29 09:42:14 +0000
committerrschnekenbu2013-08-29 09:42:14 +0000
commit98b197aa7d3d49fdf4a6a823b941bb17e6ece722 (patch)
treeb1f35bc92180a53e71edf78eb82183ce049081ff /sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource
parentbce50c67efdfd064fe2fc0df5852592a2373728a (diff)
downloadorg.eclipse.papyrus-98b197aa7d3d49fdf4a6a823b941bb17e6ece722.tar.gz
org.eclipse.papyrus-98b197aa7d3d49fdf4a6a823b941bb17e6ece722.tar.xz
org.eclipse.papyrus-98b197aa7d3d49fdf4a6a823b941bb17e6ece722.zip
Update the tests for the change strategy command.
Now tests the 3 strategies to 3 strategies matrix.
Diffstat (limited to 'sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource')
-rw-r--r--sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource/src/org/eclipse/papyrus/uml/profile/externalresource/helper/PapyrusStereotypeApplicationHelper.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource/src/org/eclipse/papyrus/uml/profile/externalresource/helper/PapyrusStereotypeApplicationHelper.java b/sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource/src/org/eclipse/papyrus/uml/profile/externalresource/helper/PapyrusStereotypeApplicationHelper.java
index a8aa71cadfc..7dc45da2678 100644
--- a/sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource/src/org/eclipse/papyrus/uml/profile/externalresource/helper/PapyrusStereotypeApplicationHelper.java
+++ b/sandbox/ExternalResourceStereotypeApplication/org.eclipse.papyrus.uml.profile.externalresource/src/org/eclipse/papyrus/uml/profile/externalresource/helper/PapyrusStereotypeApplicationHelper.java
@@ -66,19 +66,19 @@ public class PapyrusStereotypeApplicationHelper extends StereotypeApplicationHel
/**
* Returns the specific location strategy to use for the given model element
* @param element the stereotyped element
- * @return the location strategy or <code>null</code> if none was found
+ * @return the location strategy or the standard one if none was found
*/
public static IStereotypeApplicationLocationStrategy getCurrentLocationStrategy(EObject element) {
EObject container = EcoreUtil.getRootContainer(element, true);
if(container instanceof Element) {
EAnnotation annotation = ((Element)container).getEAnnotation(PAPYRUS_EXTERNAL_RESOURCE_EANNOTATION_SOURCE);
if(annotation == null) {
- return null;
+ return StrategyRegistry.getInstance().getStrategy(StandardApplicationLocationStrategy.ID);
}
String location = annotation.getDetails().get(LOCATION_STRATEGY_KEY);
if(location == null) {
- return null;
+ return StrategyRegistry.getInstance().getStrategy(StandardApplicationLocationStrategy.ID);
}
IStereotypeApplicationLocationStrategy strategy = StrategyRegistry.getInstance().getStrategy(location);
@@ -86,7 +86,7 @@ public class PapyrusStereotypeApplicationHelper extends StereotypeApplicationHel
return strategy;
}
}
- return null;
+ return StrategyRegistry.getInstance().getStrategy(StandardApplicationLocationStrategy.ID);
}
/**

Back to the top