aspose file tools*
The moose likes Java in General and the fly likes JRE and JVM interview Question .... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "JRE and JVM interview Question ...." Watch "JRE and JVM interview Question ...." New topic
Author

JRE and JVM interview Question ....

sunil choudhary
Ranch Hand

Joined: Nov 10, 2000
Posts: 141

I was asked the difference between the two...
I said..that JRE can stand alone run the java applications in case of Resource shortages.. and can function without JVM also..

Can some one add some more things to this aspect....
Please
.....
Sunil

"Learning is weightless, a treasure you can always carry easily." -Chinese Proverb
rani bedi
Ranch Hand

Joined: Feb 06, 2001
Posts: 358
The JRE (Java Runtime Environment) is the equivalent of a JVM but for running applications outside of a browser (like from the DOS prompt).
When you run an applet or servlet it is running in a JVM (Java Virtual Machine). It is actually a set of specifications that Sun gives to the makers of browsers to follow when creating their JVMs.


Cheers,<br />Rani<br />SCJP, SCWCD, SCBCD
sunil choudhary
Ranch Hand

Joined: Nov 10, 2000
Posts: 141

so parmeet
Does that mean that when I compile a program from Dos prompt then I am just using the JRE and not JVM ..are they really separate or just a subset...
thanks for your reply..
Sunil Choudhary

Scott Pedigo
Greenhorn

Joined: Feb 15, 2001
Posts: 15
The JRE is a product from Sun which has a JVM in it.
A JVM is an implementation of Sun's specifications for something - could be hardware, could be software, could be a browser - which interprets the Java byte code, executing it on a platform.
sunil choudhary
Ranch Hand

Joined: Nov 10, 2000
Posts: 141

Thanks Scott
I got the point...
Sunil
Cindy Glass
"The Hood"
Sheriff

Joined: Sep 29, 2000
Posts: 8521
Actually the SDK has the JRE in it.
If you compile from the prompt you are using the SDK. If you run from the prompt you are using the JRE.


"JavaRanch, where the deer and the Certified play" - David O'Meara
sunil choudhary
Ranch Hand

Joined: Nov 10, 2000
Posts: 141

Thanks Cindy
Sunil Choudhary
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: JRE and JVM interview Question ....
 
Similar Threads
JVM ?
Core Java
JVM and JRE
Context give: Cannot load JDBC driver class 'com.microsoft.sqlserver.jdbc.SQLServerDriver'
Where can I see JVM on my system