Java notes
🔹 Java – Overview
Java is a high-level, object-oriented, platform-independent programming
language.
Follows WORA principle: Write Once, Run Anywhere (JVM executes Java
bytecode).
🔹 Key Features
Object-Oriented: Uses classes, objects, inheritance, polymorphism,
abstraction, encapsulation.
Platform Independent: Code compiles to bytecode which runs on JVM.
Robust & Secure: Automatic memory management (Garbage Collection),
strong exception handling.
Multithreaded: Supports concurrent execution.
Portable: Standard libraries ensure consistent performance across systems.
Distributed: Supports RMI, sockets, and network programming.
🔹 Java Architecture
1. JDK – Java Development Kit (compiler + tools)
2. JRE – Java Runtime Environment (libraries + JVM)
3. JVM – Java Virtual Machine (executes bytecode)
🔹 Basic Syntax
Every program must have a class.
Entry point:
Java notes 1
public static void main(String[] args)
🔹 Data Types
Primitive: byte, short, int, long, float, double, char, boolean
Non-primitive: String, Arrays, Classes, Interfaces
🔹 OOP Concepts
Class & Object
Inheritance
Polymorphism (compile-time & runtime)
Encapsulation
Abstraction (abstract class, interface)
🔹 Important Java Components
Packages – Group of classes (e.g., [Link], [Link])
Collections Framework – List, Set, Map, Queue
Exception Handling – try, catch, finally, throw, throws
Threads – Thread class, Runnable interface
🔹 Common Keywords
this , super , static , final , abstract , extends , implements , synchronized
🔹 Common Uses of Java
Web applications (Spring Boot)
Android development
Enterprise applications
Java notes 2
Desktop tools
Cloud applications
Java notes 3