Home >Java >Javagetting Started >What are jdk, jre, and jvm? What's the connection?
JDK Introduction
JDK is the abbreviation of Java Development Kit and is a development tool kit for Java.
JDK: Java Development ToolKit (Java Development Tool Kit). JDK is the core of the entire JAVA, including Java Runtime Environment (JRE), Java tools (javac/java/jdb, etc.) and Java basic class libraries (i.e. Java API).
JRE Introduction
JRE is a Java runtime environment, not a development environment, so it does not include any development tools (such as compilers and debuggers), but is only for Users using Java programs.
JRE (Java Runtime Environment, Java runtime environment), including JVM standard implementation and Java core class library. JRE contains Java virtual machine (JVM), runtime class libraries and Java application launcher, which are necessary components to run Java programs. Through it, Java developers can release the programs they develop to users for use.
(Free learning video tutorial sharing: java video tutorial)
Introduction to JVM
JVM is Java Virtual Machine (Java The abbreviation of Virtual Machine), it is a fictitious computer that is implemented by simulating various computer functions on an actual computer.
JVM (Java Virtual Mechanal), Java virtual machine, is part of JRE. It is the core part of the entire Java cross-platform implementation. It is responsible for interpreting and executing bytecode files. It is a virtual computer that can run Java bytecode files. The JVM on all platforms provides the same interface to the compiler, and the compiler only needs to face the virtual machine, generate code that the virtual machine can recognize, and then be interpreted and executed by the virtual machine.
When you use the Java compiler to compile a Java program, platform-independent bytecode is generated, and these bytecodes are only for the JVM. The JVMs of different platforms are different, but they all provide the same interface. The JVM is a key part of the cross-platform nature of Java programs. As long as corresponding virtual machines are implemented for different platforms, the compiled Java bytecode can run on that platform.
JDK&JRE&JVM FAQ
1. What is the difference between JDK and JRE?
2. What is the relationship between JDK&JRE&JVM?
#The cross-platform principle of Java? How to achieve "write once, run many places"?
When you use the Java compiler to compile a Java program, platform-independent bytecode is generated, and these bytecodes are only for the JVM. The JVMs of different platforms are different, but they all provide the same interface. The JVM is a key part of the cross-platform nature of Java programs. As long as corresponding virtual machines are implemented for different platforms, the compiled Java bytecode can run on that platform.
Recommended related articles and tutorials: java quick start
The above is the detailed content of What are jdk, jre, and jvm? What's the connection?. For more information, please follow other related articles on the PHP Chinese website!