Java Tutorial

JVM-Architecture

Execute engine

JVM Architecture

When a JVM is compiling in a java program in that context JVM is known as compiler. When a JVM is running a java program in that context JVM is known as interpreter.

JVM reads the byte code of .class line by line. Byte codes are set of optimized instructions which are used by JVM for generating the result of the java programs.

Method interface in the JVM architecture represents the middle man role between JVM (execution engine) and java API. Java API contains collection of packages.

TOOLS used in JDK

Tools are nothing but the exe file which are developed by SUN micro system to run various applications of java, J2EE.

1. appletviewer:

This is a tool used for running applet application when the browser is not supporting properly.

2. Jar:

Jar stands for java archive. We use jar file for developing business component or application class (In J2EE applications we generate jar file for EJB applications).

War stands for web archive used for developing web components (Servlets and JSP are called web components).

Syntax for create war/jar file:

jar cfv filename.war/jar *.class

For example:

jar cfv programming.jar *.class

3. java: It is used to run a java program.

4. javac: It is used to compile a java program.

5. javap: It is used to see the API of the specific class or interface which belongs to a specified package.