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 199094

Summary: Add code completion for VM args
Product: java Reporter: kitfox <kitfox>
Component: ProjectAssignee: Tomas Zezula <tzezula>
Status: NEW ---    
Severity: normal CC: jglick
Priority: P3    
Version: 7.0   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:

Description kitfox 2011-06-01 20:46:16 UTC
It would be really useful to have a checkbox in a projects run properties that adds the 'enable assert' flag to the runtime command line.
Comment 1 Jesse Glick 2011-06-02 17:32:54 UTC
You can just add "-ea" to Run / VM Options. I am not sure a new checkbox is needed for this, though it might be mentioned in the hint below the text field.

(Adding a checkbox is tricky in case an existing project had -ea in VM Options; during customization, would need to parse the options and pull this out, then add it back in during save. But there have been some reason why it was located in a particular position in the options.)
Comment 2 Jesse Glick 2011-06-02 17:37:00 UTC
Another possibility is to offer code completion on known option names. (Could run 'java -help' followed by 'java -X' using the selected JDK, and grep for /^ +-[a-zA-Z]+/.)
Comment 3 Tomas Zezula 2011-06-03 07:00:40 UTC
I vote for the second option (the code completion).
There is already lots of UI controls and adding a new one does not scale.
Comment 4 Tomas Zezula 2011-06-08 09:39:40 UTC
Also there is "Customize" button in the J2SE Project properties (VM options) where are the checkboxes.
The Customize panel is in my opinion worse than the proposed code completion.