A friendly place for programming greenhorns!
Big Moose Saloon
Search
|
Java FAQ
|
Recent Topics
Register / Login
JavaRanch
»
Java Forums
»
Java
»
Beginning Java
Author
only 1 public class per source file
shivam aggarwal
Greenhorn
Joined: Oct 15, 2009
Posts: 8
posted
Oct 15, 2009 08:35:23
0
we can have only 1 public class per source file and that source file must be named (name of public class.java).why?
fred rosenberger
lowercase baba
Bartender
Joined: Oct 02, 2003
Posts: 9939
6
I like...
posted
Oct 15, 2009 08:43:41
0
because it makes implementing the JVM easier.
Never ascribe to malice that which can be adequately explained by stupidity.
I agree. Here's the link:
http://aspose.com/file-tools
subject: only 1 public class per source file
Similar Threads
Class using Main without declaring itself Public
source file?
Public class
Why should there be only one public class per source file
Abstract class
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter