We must understand the differences between JDK, JRE, and JVM before proceeding further to Java.


JVM

JVM (Java Virtual Machine) is an abstract machine. It is called a virtual machine because it is not physically present. An adjective that provides a runtime environment in which Java bytecode can be executed. It can also run those programs written in other languages ​​and integrated into Java bytecode.

JVMs are available on most hardware and software platforms. JVM, JRE, and JDK depend on the platform because the configuration of each OS is different from each other. However, Java is an independent platform. There are three JVM concepts:specification, implementation, and instance.

The JVM performs the following main tasks:

  • Loads code
  • Verifies code
  • Executes code
  • Provides runtime environment

JRE

JRE is a acronym of Java Runtime Environment. Rewritten as Java RTE. Java Runtime Environment is a collection of software tools used to develop Java applications. It is used to provide a runtime environment. It is a implementation of JVM. It exists physically. Contains a collection of libraries + and other files used by JVM during runtime.

The implementation of JVM is also actively released by other companies besides Sun Micro Systems.

JRE



JDK

JDK is an acronym for Java Development Kit. Java Development Kit (JDK) is a software development tool used to develop Java applications and applets. It exists physically. Contains JRE + development tools.

JDK is an implementation of any one of the below given Java Platforms released by Oracle Corporation:

  •     Standard Edition Java Platform
  •     Enterprise Edition Java Platform
  •     Micro Edition Java Platform

JDK contains a Java Virtual Machine (JVM) private machine and other resources such as interpreter/loader (Java), a compiler (javac), an archiver (jar), a documentation generator (Javadoc), etc. to complete the development of a Java Application.