It's not a secret anymore!
The moose likes Beginning Java and the fly likes What is difference between JDK, JRE and JVM? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "What is difference between JDK, JRE and JVM?" Watch "What is difference between JDK, JRE and JVM?" New topic
Author

What is difference between JDK, JRE and JVM?

Minal Silimkar-Urankar
Ranch Hand

Joined: Nov 25, 2007
Posts: 136
To compile the java program we requires compiler.
In jdk, we have javac.exe, which is responsible for compilation of the program, which generates bytecode (.class file) .

To run the bytecode (.class file), we require java run time environment JRE, which is given by java.exe. In jdk as well as in jre we have java.exe.

javac.exe and java.exe both launches the jvm for compilation as well as to run the program?


Minal Silimkar
Santhosh Kumar
Ranch Hand

Joined: Nov 07, 2000
Posts: 242
Your understanding is correct except

javac.exe and java.exe both launches the jvm for compilation as well as to run the program?


javac.exe doens't launch the jvm, only java.exe does.
Ulf Dittmer
Rancher

Joined: Mar 22, 2005
Posts: 42958
    
  73
javac.exe doens't launch the jvm

The Java compiler is written in Java, so, yes, javac.exe lanuches a JVM.
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14957
    
  26

See question and answer #18 in our Java Beginners FAQ.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: What is difference between JDK, JRE and JVM?
 
It's not a secret anymore!