Last Updated on by Karina Shakya
Java Architecture:
- Java architecture is the collection of JRE,JDK JVM components.
- Integrates the process of compilation and integration.
- Explains each and every step on how java programs are compiled and executed.
- Java architecture can be further explained by following steps.
- There is a process of compilation and interpretation in Java.
- Java compiler converts java code into bytecode.
- After that JVM converts the byte code into machine code.
- The machine code is then executed by machine.
The following figure represents the Java architecture.
Components of Java Architecture
Java architecture includes three major components. They are:
- Java Virtual Machine(JVM)
- Java Runtime Environment(JRE)
- Java Development Kit(JDK)
Java Virtual Machine(JVM)
WORA is the most important element of Java. Write Once, Run Anywhere is the acronym for Write Once, Run Anywhere. We may write our code once and use it anywhere, on any operating system, according to the feature. Because of the Java Virtual Machine, our Java software can execute on any platform. It is a Java platform component that provides us with a platform through which to run Java programs. The primary function of the JVM is to translate bytecode to machine code. First and foremost, the JVM loads and verifies the code in memory. The code is then executed and a runtime environment is provided.
Java Runtime Environment (JRE)
It provides an environment in which Java programs are executed. JRE takes our Java code, integrates it with the required libraries, and then starts the JVM to execute it. To learn more about the Java Runtime Environment.
Java Development Kit (JDK)
It is a software development environment used in the development of Java applications and applets. Java Development Kit holds JRE, a compiler, an interpreter or loader, and several development tools in it.
Java Buzzwords
The primary objective of Java Programming language creation was to make it portable, simple and secure programming language. Apart from this, there are also some excellent features which play an important role in the popularity of this language. The features of Java are also known as Java buzzwords.
The list of major Java feature or buzzwords are given below:
- Simple
- Object-oriented
- Portable
- Platform independent
- Secured
- Robust
- Architecture neutral
- Interpreted
- High performance
- Multithreaded
- Distributed
- Dynamic
Path and ClassPath variables
Path variable in Java: Once you installed Java on your machine, it is required to Set the PATH environment variable to conveniently run the executable (javac.exe, java.exe, javadoc.exe, and so on) from any directory without having to type the full path of the command, such as: C:\javac TestClass.java
path variable is used to set the path for all Java software tools like javac.exe, java.exe, javadoc.exe, and so on.
ClassPath Variables: Classpath is system environment variable used by the Java compiler and JVM.Java compiler and JVM is used Classpath to determine the location of required class files.classpath variable is used to set the path for java classes.
Sample Java Program
Also checkout fundamentals of Java Programming.