INTRODUCTION OF JAVA
HISTORY OF JAVA:
Java originated in the early 1990s at Sun Microsystems, led by
James Gosling. It was designed for platform-independent programming, initially
targeting consumer electronics like set-top boxes.
Origins
The project started as the "Green Project" in 1991, aiming to create a language
simpler and more secure than C++. After trying C++ and renaming from "Oak" (due
to trademark issues) to "Java" (inspired by coffee), it evolved for broader use.
Key Milestones
Java's first public release, JDK 1.0, launched in January 1996, introducing "Write
Once, Run Anywhere" via the JVM. Sun was acquired by Oracle in 2010, which now
stewards its development through six-month releases and LTS versions like 11, 17,
and 21
Naming Evolution
Initially codenamed "Green" (or "Greentalk"), it became "Oak" after a tree outside
Gosling's office. Trademark issues with Oak Technologies led to a brainstorming
session; "Java," inspired by Indonesian coffee, was selected over options like "Silk" or
"Lyric" for its appeal and availability
Version Release Year Notable Features
JDK 1.0 1996 Initial release, applets
J2SE 5.0 2004 Generics, annotations
Java SE 8 2014 Lambdas, Streams
Java SE 17 2021 Sealed classes (LTS)
, Java SE 21 2023 Virtual threads (LTS)
Java SE 24 2025 Latest enhancements
PRINCIPLES OF JAVA :
Java's core principles revolve around object-oriented programming (OOP) and its
design philosophy of simplicity, portability, and robustness. These make it reliable
for everything from mobile apps to enterprise systems.
OOP Pillars
Java emphasizes four main OOP concepts that structure code around objects and
real-world modeling.
● Encapsulation: Bundles data and methods into classes, hiding internal details
via access modifiers like private; exposes only necessary parts through public
getters/setters.
● Inheritance: Allows a child class to inherit properties and behaviors from a
parent class using extends, promoting code reuse while supporting single and
multilevel inheritance (no multiple inheritance for classes).
● Polymorphism: Enables objects to take multiple forms, via method overriding
(runtime) or overloading (compile-time), for flexible code like treating a
parent reference to a child object.
● Abstraction: Hides complexity by showing only essential features,
implemented through abstract classes or interfaces with methods like
abstract void method();.
Design Principles
Beyond OOP, Java follows key tenets for cross-platform reliability.
● Write Once, Run Anywhere (WORA): Bytecode runs on any JVM, ensuring
platform independence.
● Simple and Familiar: C/C++-like syntax without pointers or manual memory
management, reducing errors.
● Secure: Sandboxed execution, no direct memory access, and bytecode
verification prevent vulnerabilities.
HISTORY OF JAVA:
Java originated in the early 1990s at Sun Microsystems, led by
James Gosling. It was designed for platform-independent programming, initially
targeting consumer electronics like set-top boxes.
Origins
The project started as the "Green Project" in 1991, aiming to create a language
simpler and more secure than C++. After trying C++ and renaming from "Oak" (due
to trademark issues) to "Java" (inspired by coffee), it evolved for broader use.
Key Milestones
Java's first public release, JDK 1.0, launched in January 1996, introducing "Write
Once, Run Anywhere" via the JVM. Sun was acquired by Oracle in 2010, which now
stewards its development through six-month releases and LTS versions like 11, 17,
and 21
Naming Evolution
Initially codenamed "Green" (or "Greentalk"), it became "Oak" after a tree outside
Gosling's office. Trademark issues with Oak Technologies led to a brainstorming
session; "Java," inspired by Indonesian coffee, was selected over options like "Silk" or
"Lyric" for its appeal and availability
Version Release Year Notable Features
JDK 1.0 1996 Initial release, applets
J2SE 5.0 2004 Generics, annotations
Java SE 8 2014 Lambdas, Streams
Java SE 17 2021 Sealed classes (LTS)
, Java SE 21 2023 Virtual threads (LTS)
Java SE 24 2025 Latest enhancements
PRINCIPLES OF JAVA :
Java's core principles revolve around object-oriented programming (OOP) and its
design philosophy of simplicity, portability, and robustness. These make it reliable
for everything from mobile apps to enterprise systems.
OOP Pillars
Java emphasizes four main OOP concepts that structure code around objects and
real-world modeling.
● Encapsulation: Bundles data and methods into classes, hiding internal details
via access modifiers like private; exposes only necessary parts through public
getters/setters.
● Inheritance: Allows a child class to inherit properties and behaviors from a
parent class using extends, promoting code reuse while supporting single and
multilevel inheritance (no multiple inheritance for classes).
● Polymorphism: Enables objects to take multiple forms, via method overriding
(runtime) or overloading (compile-time), for flexible code like treating a
parent reference to a child object.
● Abstraction: Hides complexity by showing only essential features,
implemented through abstract classes or interfaces with methods like
abstract void method();.
Design Principles
Beyond OOP, Java follows key tenets for cross-platform reliability.
● Write Once, Run Anywhere (WORA): Bytecode runs on any JVM, ensuring
platform independence.
● Simple and Familiar: C/C++-like syntax without pointers or manual memory
management, reducing errors.
● Secure: Sandboxed execution, no direct memory access, and bytecode
verification prevent vulnerabilities.