[Uml-devel] branches/KDE/3.5/kdesdk/umbrello
Oliver Kellogg
okellogg at users.sourceforge.net
Fri Aug 4 05:59:05 UTC 2006
SVN commit 569520 by okellogg:
Patch by JP Fournier helps avoid creation of unwanted placeholder types
for unqualified type names mentioned in method parameters.
BUG:131825
M +1 -0 ChangeLog
M +7 -1 umbrello/codeimport/javaimport.cpp
--- branches/KDE/3.5/kdesdk/umbrello/ChangeLog #569519:569520
@@ -4,6 +4,7 @@
* Java import - importing interfaces - absent visibility treated as package
instead of public (131327)
* Python code generation not independent of diagram view (131790)
+* Java import - method parameter types not resolved correctly (131825)
Version 1.5.4
--- branches/KDE/3.5/kdesdk/umbrello/umbrello/codeimport/javaimport.cpp #569519:569520
@@ -308,7 +308,7 @@
}
if (m_source[m_srcIndex] == "extends") {
const QString& baseName = advance();
- // try to resove the class we are extending, or if impossible
+ // try to resolve the class we are extending, or if impossible
// create a placeholder
UMLObject *parent = resolveClass( baseName );
if ( parent ) {
@@ -463,6 +463,12 @@
while (m_srcIndex < srcLength && m_source[m_srcIndex] != ")") {
QString typeName = joinTypename();
QString parName = advance();
+ // the Class might not be resolved yet so resolve it if necessary
+ UMLObject *obj = resolveClass(typeName);
+ if (obj) {
+ // by prepending the package, unwanted placeholder types will not get created
+ typeName = obj->getFullyQualifiedName(".");
+ }
UMLAttribute *att = Import_Utils::addMethodParameter(op, typeName, parName);
if (advance() != ",")
break;
More information about the umbrello-devel
mailing list