Topic 1_Introduction to Java Programming (1)
Topic 1_Introduction to Java Programming (1)
What is Java?
On 13 November, 2006, Sun released much of Java as free and open source software
under the terms of the GNU General Public License (GPL).
On 8 May, 2007, Sun finished the process, making all of Java's core code free and
opensource, aside from a small portion of code to which Sun did not hold the
copyright.
Components of Java Programming Language?
When you run the Java program, Java compiler first compiles your Java code to
bytecode. Then, the JVM translates bytecode into native machine code (set of
instructions that a computer's CPU executes directly).
Java JDK, JRE and JVM
What is JRE?
JRE (Java Runtime Environment) is a software package that provides Java class
libraries, Java Virtual Machine (JVM), and other components that are required to run
Java applications.
1. Java Platform, Standard Edition (Java SE): Java SE’s API offers the Java
programming language’s core functionality. It defines all the basis of type and object
to high-level classes. It is used for networking, security, database access, graphical
user interface (GUI) development, and XML parsing.
2. Java Platform, Enterprise Edition (Java EE): The Java EE platform offers an API and
runtime environment for developing and running highly scalable, large-scale, multi-
tiered, reliable, and secure network applications.
3. Java Programming Language Platform, Micro Edition (Java ME): The Java ME
platform offers an API and a small-footprint virtual machine running Java programming
language applications on small devices, like mobile phones.
4. Java FX: JavaFX is a platform for developing rich internet applications using a
lightweight user-interface API.
Features of Java?
The Java Features given below are simple and easy to understand.
1. Simple
2. Object-Oriented
3. Portable
4. Platform independent
5. Secured
6. Robust
7. Architecture neutral
8. Dynamic
9. Interpreted
10. High Performance
11. Multithreaded
12. Distributed
Features of Java?
Simple: Java is a simple language that can be learned easily even if you have just
started programming. It was designed to be easy to learn and use effectively.
Portable: Java enables the creation of a program that runs on any platform without
changing the source code of the program. i.e. Java creates a cross-platform programs
by compiling the programs into an intermediate representation called Java Bytecode.
Bytecode is the result of compiling a Java program. You can execute the code on any
platform. Converting a Java program into Bytecode makes it portable because any
computer installed with the JVM for the platform on which it is running can interpret
the Bytecode.
Platform Independent: Unlike many other programming languages including C and
C++, when Java is compiled, it is not compiled into platform specific machine, rather into
platform independent byte code. This byte code is distributed over the web and
interpreted by the Virtual Machine (JVM) on whichever platform it is being run on.
Robust: Java makes an effort to eliminate error prone situations by emphasizing mainly
on compile time error checking and runtime checking.
Interpreted: Java byte code is translated on the fly to native machine instructions and is
not stored anywhere. The development process is more rapid and analytical since the
linking is an incremental and light-weight process.
High Performance: With the use of Just-In-Time compilers, Java enables high
performance.