Version: 1.5.1 (using KDE 3.4.2 Level "b" , SUSE 10.0) Compiler: Target: x86_64-suse-linux OS: Linux (x86_64) release 2.6.13-15.8-smp Importing interfaces will stop after the first method declaration. After the import finds a method declaration it assumes that this declaration is always stopped by a '}'. But this is not true. Abstract methods are stopped with the trailing ';'. I have a solution to provide. I'm not familiar with diff/patch so i provide the following snippet. I hope that one of the maintainers can use it. File: javaimport.cpp Line: 313 Import_Utils::insertMethod(m_klass, op, Uml::Visibility::Public, typeName, m_isStatic, m_isAbstract, false /*isFriend*/, false /*isConstructor*/, m_comment); m_isAbstract = m_isStatic = false; // ------------------------------- // At this point we do not know wether the method has a body or not // 15.3.2006 H. Herres nextToken = advance(); while (nextToken != "{" && nextToken != ";") { nextToken = advance(); } if (nextToken == ";") { // No body (interface or abstract) return true; } else { return skipToClosing('{'); } //------------------------------ } // At this point we know it's some kind of attribute declaration. while (1) { while (nextToken != "," && nextToken != ";") { name += nextToken; // add possible array dimensions to `name' nextToken = advance(); }
SVN commit 518955 by okellogg: parseStmt(): Check next token after method profile, it might be a semicolon. Thanks to Harald Herres <harald.herres_AT_control.de> for the fix. BUG:123661 M +1 -0 ChangeLog M +2 -1 THANKS M +10 -1 umbrello/javaimport.cpp --- branches/KDE/3.5/kdesdk/umbrello/ChangeLog #518954:518955 @@ -26,6 +26,7 @@ * Crash when creating a datatype with the same name as a class (122188) * Memory problem when importing classes from c++ sources (122668) * Crash when refusing to rename a class on importing typedef (122914) +* Java import fails at abstract methods or interfaces (123661) Version 1.5.1 --- branches/KDE/3.5/kdesdk/umbrello/THANKS #518954:518955 @@ -33,8 +33,9 @@ Esben Mose Hansen <esben @despammed.com> Olaf Hartig <OleBowle @gmx.de> Marius Helf <marius.helf @gmx.de> +Paul Hensgen <phensgen @bigpond.net.au> Michel Hermier <michel.hermier @wanadoo.fr> -Paul Hensgen <phensgen @bigpond.net.au> +Harald Herres <harald.herres @control.de> David Hugh-Jones <hughjonesd @yahoo.co.uk> Pekka J