Java Development Kit || Introduction to Java || Bcis Notes

Java Development Kit || Introduction to Java || Bcis Notes

Java Development Kit:

The Java Development Kit (JDK) is a software development environment used for developing Java applications and applets. It includes the Java Runtime Environment (JRE), an interpreter/loader (java), a compiler (javac), an archiver (jar), a documentation generator (Javadoc) and other tools needed in Java development.

Java Virtual Machine(JVM):

Java Virtual machine (JVM) is the virtual machine that runs the Java bytecodes. You get this bytecode by compiling the .java files into .class files. .class files contain the bytecodes understood by the JVM.
In the real world, JVM is a specification that provides a runtime environment in which Java bytecode can be executed. Different vendors provide different implementations of this specification. For example, this wiki page lists different JVM implementations.
A Most popular implementation of JVM is Hotspot which is owned and provided by Oracle Corporation. (Previously by Sun Microsystems, Inc.).
JVM delivers the optimal performance for Java applications using many advanced techniques, incorporating a state-of-the-art memory model, garbage collector, and adaptive optimizer.
JVM comes in two different flavours – client and server. Although the Server and the Client VMs are similar, the Server VM has been specially tuned to maximize peak operating speed. It is intended for executing long-running server applications, which need the fastest possible operating speed more than a fast start-up time or smaller runtime memory footprint. Developers can choose which system they want by specifying -client or -server.
The JVM is called virtual because it provides a machine interface that does not depend on the underlying operating system and machine hardware architecture. This independence from hardware and the operating system is a cornerstone of the write-once-run-anywhere value of Java programs.

The Java Runtime Environment (JRE):

The Java Runtime Environment (JRE) is a software package which bundles the libraries (jars) and the Java Virtual Machine, and other components to run applications written in the Java. JVM is just a part of JRE distributions.
To execute any Java application, you need JRE installed in the machine. It’s a minimum requirement to execute Java applications on any machine.

  JRE bundles the following components –

  • DLL files used by the Java HotSpot Client Virtual Machine.
  •  DLL files used by the Java HotSpot Server Virtual Machine.
  • Code libraries, property settings, and resource files used by the Java runtime environment. e.g. rt.jar and charsets.jar.
  • Java extension files such as localedata.jar.
  • Contains files used for security management. These include the security policy (java.policy) and security properties (java.security) files.
  • Jar files containing support classes for applets.
  • Contains TrueType font files for use by the platform.JREs can be downloaded as part of JDKs or you can download them separately. JREs are platform dependent. It means that based on the type of machine (OS and architecture), you will have to select the JRE bundle to import and install.
    For example, you cannot install a 64-bit JRE distribution on a 32-bit machine. Similarly, JRE distribution for Windows will not work in Linux; and vice-versa.

 

You may like the history of java, features of java, the misconception of java.

Be the first to comment

Leave a Reply

Your email address will not be published.


*