1 Introduction
1 Introduction
Introduction
6)Portable:
• Being platform independent , Java application
developed in one environment can be deployed to
different platform and executed using JVM.
• Java programs are portable, which means that the
same byte code program can run on any computer
system that has a Java interpreter.
• Also, a source program can be compiled into byte
codes on any computer that has a Java compiler.
Prof Amruta Deshmukh 14
8)Dynamic:
• Java programs can carry an extensive amount of run-
time information that can be used to verify
12)Distributed:
• Java is distributed because users to create
distributed applications in Java.
• RMI(Remote Method Invocation) and
EJB(Enterprise Java Bean) are used for creating
distributed applications.
• This feature of Java makes us able to access
files by calling the methods from any machine
on the internet.
Prof Amruta Deshmukh 17
What is SDK?
• SDK stands for Standard developer’s kit.
• We can write, compile and run java programs
using SDK.
• A java program can be written once and then
run on many different devices, having JVM.
• There are different SDK’s available for
different platform i.e. Windows, Linux,
Solaris…
Prof Amruta Deshmukh 18
What is JDK?
• JDK (Java Development Kit) is provided by Sun
Microsystems which comes with its own set of
tools like Java Compiler, Java Interpreter,
Applet viewer and java API’s which are set of
classes to develop java programs.
• What is Bytecode?
• Compiled java code referred to as bytecode.
• Bytecode is a highly optimized set of
instructions designed to be executed by the
JVM (Java Virtual Machine).
• Bytecode is independent of operating system.
Prof Amruta Deshmukh 19
What is JVM?
• JVM stands for Java Virtual Machine.
• Execution of every java program is under the
control of the JVM.
• Most JVMs are written in C or C++.
• JVM is responsible for the execution of java
bytecode.
[2]Enterprise edition:
• which is used for developing web applications.
• It is also known as J2EE,JEE
• https://www.eclipse.org/downloads/downloa
d.php?file=/oomph/epp/2020-12/R/eclipse-
inst-jre-win64.exe
Prof Amruta Deshmukh 27
How java program executes?
1>Create program using text editor (like
notepad) and give file extension as .java
2> Compile the source code with “javac”.
3> It will produce bytecode. i.e. .class file
4> Execute bytecode by “java” (Interpreter).
5> Obtain result or output.
Bytecode Verified:
• Variables are initialized before they are used.
• Method calls match the types of object references.
• Rules for accessing private data and methods are not violated.
• Local variable accesses fall within the runtime stack.
• The run-time stack does not overflow.
• If any of the above checks fail, the verifier doesn’t allow the
class to be loaded.
• }
• }
• }
• if(c==0)
• System.out.println("It is a Prime Number");
• else
• System.out.println("It is not Prime Number");
• }