[Uml-devel] kdesdk/umbrello/umbrello

Oliver Kellogg okellogg at users.sourceforge.net
Sun Nov 9 13:30:05 UTC 2003


CVS commit by okellogg: 

getClassesAndInterfaces(): Let the returned list also contain UMLEnums.


  M +8 -5      umldoc.cpp   1.100


--- kdesdk/umbrello/umbrello/umldoc.cpp  #1.99:1.100
@@ -1883,9 +1883,10 @@ QStringList UMLDoc::getModelTypes()
 UMLClassifierList UMLDoc::getConcepts() {
         UMLClassifierList conceptList;
-        for(UMLObject *obj = objectList.first(); obj ; obj = objectList.next())
-                if(obj -> getBaseType() == ot_Class || obj->getBaseType() == ot_Interface
-                   || obj->getBaseType() == ot_Datatype || obj->getBaseType() == ot_Enum)  {
+        for(UMLObject *obj = objectList.first(); obj ; obj = objectList.next()) {
+                Uml::UMLObject_Type ot = obj->getBaseType();
+                if(ot == ot_Class || ot == ot_Interface || ot == ot_Datatype || ot == ot_Enum)  {
                         conceptList.append((UMLClassifier *)obj);
                 }
+        }
         return conceptList;
 }
@@ -1893,8 +1894,10 @@ UMLClassifierList UMLDoc::getConcepts() 
 UMLClassifierList UMLDoc::getClassesAndInterfaces() {
         UMLClassifierList conceptList;
-        for(UMLObject* obj = objectList.first(); obj ; obj = objectList.next())
-                if(obj->getBaseType() == ot_Class || obj->getBaseType() == ot_Interface)  {
+        for(UMLObject* obj = objectList.first(); obj ; obj = objectList.next()) {
+                Uml::UMLObject_Type ot = obj->getBaseType();
+                if(ot == ot_Class || ot == ot_Interface || ot == ot_Enum)  {
                         conceptList.append((UMLClassifier *)obj);
                 }
+        }
         return conceptList;
 }






More information about the umbrello-devel mailing list