A Learning Journey

–By Sharing Knowledge

Chapter-V: Java Compilation and Interpretation

Posted by krishnamm on February 18, 2009

Chapter-V

 

In Last chapter we learn about the simple java program. In this chapter we will learn about how the compilation and interpretation happened internally.

Once you write the program and try to compile it using Javac command… the JVM will complile the program.

What is JVM?

JVM: Java Virtual Machine, which contains the JDK as well as JRE. it provides the java environment.

JDK: Java Development toolkit. have compiler.

JRE: Java Runtime environment. this is for run the application or program

JVM = JDK+JRE;

To develop and run a java program we require JVM. but for running a java program JVM need not be required (As JRE come with OS). We already discuss about this in previous chapters.

Once the compilation successfully done, a .class file will generated… we can run this .class file using interpreter, after interpretation, the .exe file will be generated.

Why JVM is Plotform Dependent?

Java “the language” is platform-independent. To make it so, there is a platform-specific JRE that knows how to run the platform-independent Java code on a specific platform. So JVM is plotform dependent.

****************************************************************************************************************************************************************************

Summary

  •  Java is OOPs programming language and plotform independent language.
  • Java compilation and running is a two step process called compilation+interpratation
  • Java is secure becasue of byte code as well as interpretation.
  • To develop a java application we require JVM
  • JVM = JDK+JRE.
  • JVM is plotform dependent.
  • The file should be saved with same name as classname.

In further chapters we will learn about the other things like variables, keywords, method signatures etc…

 

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: