svn commit: r18112 - trunk/src/argouml-core-model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java

Bob Tarling <[email protected]>
Newsgroups gmane.comp.lang.uml.argouml.cvs
Message-ID <[email protected]>
Author: bobtarling
Date: 2010-03-17 05:37:11-0700
New Revision: 18112

Modified:
   trunk/src/argouml-core-model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java

Log:
Get raised exceptions working on UML2 prop panels.
getRaisedSignals deprecated in favour of the getRaisedExceptions (moving to UML2 terminology)

Modified: trunk/src/argouml-core-model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-core-model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java?view=diff&pathrev=18112&r1=18111&r2=18112
==============================================================================
--- trunk/src/argouml-core-model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java	(original)
+++ trunk/src/argouml-core-model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java	2010-03-17 05:37:11-0700
@@ -3006,16 +3006,7 @@
 
 
     public Collection getRaisedSignals(Object handle) {
-        try {
-            if (handle instanceof BehavioralFeature) {
-                return getRefOutermostPackage(handle).getCommonBehavior()
-                        .getAContextRaisedSignal().getRaisedSignal(
-                                (BehavioralFeature) handle);
-            }
-        } catch (InvalidObjectException e) {
-            throw new InvalidElementException(e);
-        }
-        return illegalArgumentCollection(handle);
+        return getRaisedExceptions(handle);
     }
     
     /**
@@ -3026,9 +3017,14 @@
      * @see org.argouml.model.Facade#getRaisedExceptions(java.lang.Object)
      */
     public Collection getRaisedExceptions(Object handle) {
-        if (handle instanceof Operation) {
-            throw new NotImplementedException(
-                    "There are no exceptions in UML 1.x operations"); 
+        try {
+            if (handle instanceof BehavioralFeature) {
+                return getRefOutermostPackage(handle).getCommonBehavior()
+                        .getAContextRaisedSignal().getRaisedSignal(
+                                (BehavioralFeature) handle);
+            }
+        } catch (InvalidObjectException e) {
+            throw new InvalidElementException(e);
         }
         return illegalArgumentCollection(handle);
     }

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

To unsubscribe from this discussion, e-mail: [[email protected]].
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.