Author: thn
Date: 2010-12-08 01:50:27-0800
New Revision: 18901

Modified:
   
trunk/src/argouml-core-model-euml/src/org/argouml/model/euml/ExtensionMechanismsHelperEUMLImpl.java

Log:
only apply defined profiles

Modified: 
trunk/src/argouml-core-model-euml/src/org/argouml/model/euml/ExtensionMechanismsHelperEUMLImpl.java
Url: 
http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-core-model-euml/src/org/argouml/model/euml/ExtensionMechanismsHelperEUMLImpl.java?view=diff&pathrev=18901&r1=18900&r2=18901
==============================================================================
--- 
trunk/src/argouml-core-model-euml/src/org/argouml/model/euml/ExtensionMechanismsHelperEUMLImpl.java
 (original)
+++ 
trunk/src/argouml-core-model-euml/src/org/argouml/model/euml/ExtensionMechanismsHelperEUMLImpl.java
 2010-12-08 01:50:27-0800
@@ -86,10 +86,12 @@
 
     public void applyProfile(Object handle, Object profile) {
         if (profile instanceof Profile) {
-            if (handle instanceof Model) {
-                ((Model) handle).applyProfile((Profile) profile);
-            } else if (handle instanceof Profile) {
-                ((Profile) handle).applyProfile((Profile) profile);
+            if (((Profile) profile).isDefined()) {
+                if (handle instanceof Model) {
+                    ((Model) handle).applyProfile((Profile) profile);
+                } else if (handle instanceof Profile) {
+                    ((Profile) handle).applyProfile((Profile) profile);
+                }
             }
             // also apply subprofiles:
             Iterator<Package> iter = ((Profile) profile).getNestedPackages()

------------------------------------------------------
http://argouml.tigris.org/ds/viewMessage.do?dsForumId=5905&dsMessageId=2688714

To unsubscribe from this discussion, e-mail: 
[[email protected]].

Reply via email to