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.

Bug 142718

Summary: Code Gen generates an empty java source file
Product: uml Reporter: shche123 <shche123>
Component: Code GenerationAssignee: Viktor Lapitski <lvv>
Status: VERIFIED DUPLICATE    
Severity: blocker    
Priority: P1    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:
Attachments: zip file of java and uml projects

Description shche123 2008-08-03 19:25:09 UTC
Code Gen generates an empty java source file

Right click on the DVDItem in the Class Diagram
Open the DVDItem.java - not a single line of text...
Comment 1 shche123 2008-08-03 19:26:48 UTC
Created attachment 66415 [details]
zip file of java and uml projects
Comment 2 shche123 2008-08-03 19:46:27 UTC
getting:
========

Begin processing Generate Code: 1 items

Code Generation selected options:
  Source Folder Location - C:\instructor\SL314_C\projects\DVDLibrary\src\java
  Backup Sources - true
  Generate Markers - true
  Show Generate Code Dialog - true

Processing element 1 of 1: Class com::dvd::model::DVDItem ... 
  Generating source from template "Java/CompilationUnit.java" ...ERROR:  java.lang.NullPointerException
Error While Processing Element java.lang.NullPointerException

================================
Task Failed (total time: 0 seconds)

-----------
as soon as delete all the constructors, code gens OK

Comment 3 Viktor Lapitski 2008-08-04 22:29:58 UTC
I can't reproduce the issue using current 6.5 build. 
Looking into the model of the attached project it looks like 
the issue 134878 (operation that is constructor without having 
been marked so) that is already fixed in 6.5.

*** This issue has been marked as a duplicate of 134878 ***
Comment 4 Peter Lam 2008-08-04 22:45:42 UTC
verified in NB 6.5 UML daily build 20080804. The problem no longer exists.