Chap 1
Chap 1
run interpreter
execute a program
• Java is guaranteed to be Write Once, Run Anywhere
Basic features of
java(Buzzwords)
• Object Oriented : In java everything is an Object. Java can be easily
extended since it is based on the Object model.
• Basic features is
•OPSSAPRMIHDD
History of java
• James Gosling initiated the Java language project in June 1991 for use in
one of his many set-top box projects. The language, initially called Oak
after an oak tree that stood outside Gosling's office, also went by the
name Green and ended up later renamed as Java, from a list of random
words.
• On 8 May 2007 Sun finished the process, making all of Java's core code
free and open-source, aside from a small portion of code to which Sun
did not hold the copyright.
JAVA VIRTUAL MACHINE
CONCEPT
Java interpreter
for window
Java program
Java interpreter
for linux
Machine
instruction
Java is machine independent and
architectural neutral
• The java compiler reads java language source files , translates the source
into java byte codes and places the bye codes into class file.
• Any machine for which java interpreter is available can execute this byte
code
Layers of interactions for java
programs
Real machine
Operating system
Java virtual machine
compiler interpreter
users
The JVM includes:
A)Byte Code Loader : will pick up the byte code file(.class)
->this byte code is then verified to ensure that it can execute correctly
without violating any of Java’s rule or security consideration.
Any byte code file failing is rejected at this point
•The java object framework(java API) acts as the intermediary between the
users programs and the virtual machine which in turn acts
as the intermediary between the operating system and the java object
framework.