This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Processing element 1 of 2: Class Account ... Generating source from template "Java/CompilationUnit.java" ...ERROR: java.lang.NullPointerException Generates Account class with no code...
Created attachment 61278 [details] Java and UML projects
My settings do not auto add Constructor to the the Class diagram. When I do add it and then gen the code, I get the runtime error...
still exists in 6.5 as well as in 6.1. Not sure what's happening but I do get the error when generating code.
The project is somehow got into incorrect state: 1. there is a method that should be constructor, yet is doens't have isConstructor="true" 2. it has return parameter specified with empty type ( type="" ) <UML:Operation xmi.id="DCE.5F662313-A306-DE8D-5A84-F47F16E896A2" name="Account" owner="DCE.0DB1A5E7-8868-EDAD-8AED-4DCA686961A0"><UML:Element.ownedElement> <UML:Parameter xmi.id="DCE.74380533-7A08-99C3-CC16-7E20D9F16619" type="" direction="result" owner="DCE.5F662313-A306-DE8D-5A84-F47F16E896A2"> This is, for example, how a constructor is supposed to look like: <UML:Operation xmi.id="DCE.14EB7F16-7818-912F-A03E-B5B9D72BB2E0" name="cl3" isConstructor="true" owner="DCE.5FEDABB3-A0D0-18FB-8016-8EFCE9D9A9E0"><UML:Element.presentation> </UML:Element.presentation></UML:Operation> A defensive code will be added to continue work in this situation as well.
http://hg.netbeans.org/uml-main/rev/2c9c6ad6509d
this issue can't be verified yet in build 20080717 due to blocking issue 140788
reviewd
verified in 6.5 build 20080718. exception no longer occurs.
*** Issue 142718 has been marked as a duplicate of this issue. ***