svn commit: r15499 - trunk/src/argouml-app/src/org/argouml/kernel/Project.java

[email protected]
Newsgroups gmane.comp.lang.uml.argouml.cvs
Message-ID <[email protected]>
Author: tfmorris
Date: 2008-08-03 10:52:01-0700
New Revision: 15499

Modified:
   trunk/src/argouml-app/src/org/argouml/kernel/Project.java

Log:
Issue 5286: Clarify getModels API.  This has returned a HashSet since at least 0.24, so ordering is not guaranteed.

Modified: trunk/src/argouml-app/src/org/argouml/kernel/Project.java
Url: http://argouml.tigris.org/source/browse/argouml/trunk/src/argouml-app/src/org/argouml/kernel/Project.java?view=diff&rev=15499&p1=trunk/src/argouml-app/src/org/argouml/kernel/Project.java&p2=trunk/src/argouml-app/src/org/argouml/kernel/Project.java&r1=15498&r2=15499
==============================================================================
--- trunk/src/argouml-app/src/org/argouml/kernel/Project.java	(original)
+++ trunk/src/argouml-app/src/org/argouml/kernel/Project.java	2008-08-03 10:52:01-0700
@@ -276,7 +276,14 @@
 
     /**
      * Returns all top level Packages (e.g. Models), including the profile
-     * packages.
+     * packages. 
+     * <p>
+     * <em>WARNING:</em> The models returned by this method are <em>not</em>
+     * ordered.  Any code which makes the assumption that the user model is
+     * first (or any other ordering assumption) is broken!
+     * <p><em>NOTE:</em> Since user defined models and profiles are
+     * handled quite differently, you normally want to use
+     * {@link #getUserDefinedModelList()} instead of this method.
      * 
      * @return A Collection containing all models.
      */
@@ -288,7 +295,8 @@
      * If there isn't exactly one model, <code>null</code> is returned.
      *
      * @return the model.
-     * @deprecated for 0.25.4 by tfmorris.  Use {@link #getModels()}.
+     * @deprecated for 0.25.4 by tfmorris.  Use 
+     * {@link #getUserDefinedModelList()} or {@link #getModels()}.
      */
     @Deprecated
     public Object getModel();
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.