|
|
I have a protected class with a public static void main() method. In JBuilder 4, I can right-click on the class node and run the application using this class's main(). In JBuilder 6, the class node's context menu doesn't have a Run menu item. Why not? |
| I believe the answer is that the Java Language Specification says that only public classes with public static void main(String[] args) methods may be used as runtime launch points. JBuilder 4 erronously accepted any class with a public static void main(String[] args) no matter what the class's topmost protection level was.
JBuilder 6 now correctly honors the public class/public main requirements and no longer displays the Run menu items for non-public classes.
I don't know which behavior JBuilder 5 displays.
| |
| [Append to This Answer] | |
| 2002-May-23 10:36am |
| ||||||||
|
Java Community
Java Tools |
Code Central JB OpenTools |
Community Recent Threads |
Borland Chat Chat FAQ |
||||||||||||||
|
Feature Matrices 3.0 | 3.5 | 4.0 5.0 | 6.0 | 7.0 |
Shop for JBuilder |
JBuilder Downloads and reg keys |
Report Piracy | ||||||||||||||
|
Online Manuals 4.0 | 5.0 | 6.0 7.0 |
Borland DevSupport's Bug/RFE Form Quality Central Client |
JB Patches & Updates |
JBuilder FAQs TIs | ||||||||||||||
|
JBuilder Newsgroups |
Tamaracka's News Archive |
Mr. Haki's JBuilder Machine |
JGuru's JBuilder FAQ |
||||||||||||||
|
Sun's Bug Parade |
|||||||||||||||||
|
|||||||||||||||||