Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Why only one Class is public in one file? Explain in
details. Thanks in Advance.

Answer Posted / malay

I think that you call only public classes from outside.Now
all these classe are kept in a .java file.So there should
be a one to one mapping between a public class
& .java/.class file.If there are more than one public
classes then JVM has to maintain a tracker that what all
classes are in single .java/.class file.Presently its easy
for JVM coz when a class is called it simply goes & load
the .class file with that name.

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When is the arraystoreexception thrown?

1005


What are the different collection views provided by maps?

978


What is a numeric literal?

1060


What is a parent class in java?

1007


What is string [] args?

995


What is compareto () in java?

958


What is :: operator in java 8?

1000


Is java written in c?

945


What are classloaders?

1005


Why webdriver is an interface?

1041


Explain about anonymous inner classes ?

1053


How can we create a thread in java?

1011


Describe 2 different ways to concatenate two strings.

1190


How to change value in arraylist java?

1154


What is the java project architecture?

2224