svn commit: r14723 - trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java

[email protected]
Newsgroups gmane.comp.lang.uml.argouml.cvs
Message-ID <[email protected]>
Author: tfmorris
Date: 2008-05-13 09:04:55-0700
New Revision: 14723

Modified:
   trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java

Log:
Add TODOs for issue 5086

Modified: trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java?view=diff&rev=14723&p1=trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java&p2=trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java&r1=14722&r2=14723
==============================================================================
--- trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java	(original)
+++ trunk/src/argouml-app/src/org/argouml/uml/reveng/java/Modeller.java	2008-05-13 09:04:55-0700
@@ -778,12 +778,8 @@
         if (!Model.getFacade().isAClass(element)) {
             return false;
         }
-        for (Object stereotype : Model.getFacade().getStereotypes(element)) {
-            if ("enumeration".equals(Model.getFacade().getName(stereotype))) {
-                return true;
-            }
-        }
-        return false;
+        return Model.getExtensionMechanismsHelper().hasStereotype(element,
+                "enumeration");
     }
 
     /**
@@ -1022,6 +1018,8 @@
 	} else {
 	    try {
 		mClassifier =
+		    // FIXME: This can't throw away the fully qualified 
+		    // name before starting the search!
 		    getContext(returnType).get(getClassifierName(returnType));
             } catch (ClassifierNotFoundException e) {
                 if (forceIt && returnType != null && model != null) {
@@ -1734,6 +1732,11 @@
 
     /**
      * Get the classifier name from a fully specified classifier name.
+     * <p>
+     * FIXME: Most uses of this method are wrong. We should be adding context
+     * such as package names or outer classifier names, not removing it, before
+     * doing lookup so that the search methods have the fully qualified name to
+     * work with.
      * 
      * @param name A fully specified classifier name.
      * @return The classifier name.
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.