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 56730

Summary: Add method that allows Java file wizards that require non-empty package name
Product: java Reporter: Petr Jiricka <pjiricka>
Component: ProjectAssignee: apireviews <apireviews>
Status: RESOLVED FIXED    
Severity: blocker Keywords: API, API_REVIEW_FAST
Priority: P3    
Version: 4.x   
Hardware: All   
OS: All   
Issue Type: TASK Exception Reporter:
Bug Depends on:    
Bug Blocks: 53841    
Attachments: Patch: addition of one method that makes this possible

Description Petr Jiricka 2005-03-21 13:07:21 UTC
Normally, the wizard for creating Java files recommends that the user specifies
a valid package. However, in some cases it is necessary to *enforce* that a
package name is specified. So there should be an option to enforce that package
must be specified, and the Next/Finish buttons must be disabled if it is not.

This is necessary to fix issue 53841.

Attaching a patch.
Comment 1 Petr Jiricka 2005-03-21 13:13:14 UTC
Created attachment 20985 [details]
Patch: addition of one method that makes this possible
Comment 2 Petr Hrebejk 2005-03-21 15:56:38 UTC
I agree with the proposed change.
Comment 3 Pavel Buzek 2005-03-21 16:21:49 UTC
I think this can be generally useful, I agree with the patch.
Comment 4 Petr Jiricka 2005-03-23 18:54:53 UTC
Fixed.

Checking in apichanges.xml;
/cvs/java/project/apichanges.xml,v  <--  apichanges.xml
new revision: 1.7; previous revision: 1.6
done
Checking in
src/org/netbeans/spi/java/project/support/ui/templates/JavaTemplates.java;
/cvs/java/project/src/org/netbeans/spi/java/project/support/ui/templates/JavaTemplates.java,v
 <--  JavaTemplates.java
new revision: 1.14; previous revision: 1.13
done
Comment 5 Petr Jiricka 2005-03-23 18:55:31 UTC
Now really marking as fixed.
Comment 6 Petr Jiricka 2005-03-23 20:05:45 UTC
Sorry, more changes were required. I wasn't working with completely updated sources.

Checking in project/Bundle.properties;
/cvs/java/project/src/org/netbeans/modules/java/project/Bundle.properties,v  <--
 Bundle.properties
new revision: 1.32; previous revision: 1.31
done
Checking in project/JavaTargetChooserPanel.java;
/cvs/java/project/src/org/netbeans/modules/java/project/JavaTargetChooserPanel.java,v
 <--  JavaTargetChooserPanel.java
new revision: 1.25; previous revision: 1.24
done
Comment 7 Jesse Glick 2005-03-30 00:04:24 UTC
You seem to have omitted the @since tag on the newly added method.
Comment 8 Petr Jiricka 2005-03-30 08:40:14 UTC
Thanks for catching, done.

/cvs/java/project/src/org/netbeans/spi/java/project/support/ui/templates/JavaTemplates.java,v
 <--  JavaTemplates.java
new revision: 1.15; previous revision: 1.14