Basics

Terminology

Java Programming Language: Java is a high-level, object-oriented programming language developed by Sun Microsystems (now owned by Oracle). It is platform-independent, meaning Java code can run on any platform that has a Java Virtual Machine (JVM). Java is designed to be simple, robust, secure, and portable.

Object-Oriented Programming (OOP): Java is primarily an object-oriented programming language. OOP emphasizes the concept of objects, which are instances of classes. Objects have both state (attributes) and behavior (methods). Key principles of OOP include encapsulation, inheritance, and polymorphism.

Object: An object is an instance of a class. It combines data (attributes) and behavior (methods) related to a particular entity.

Data/Attributes/Fields: These are the properties or characteristics of an object. They represent the state of the object.

Behavior/Methods/Functions: These are actions that an object can perform. Methods define how an object interacts with other objects or its environment. They can modify the object's state, perform calculations, or trigger other actions.

Class: A class is a blueprint for creating objects. It defines the attributes and behaviors that objects of the class will have.

Variable: Variables are containers for storing data values.

Inheritance: Inheritance is a mechanism where a new class (subclass) inherits properties and behavior from an existing class (superclass). Subclasses can extend the functionality of their superclass and override methods.

Polymorphism: Polymorphism allows objects of different classes to be treated as objects of a common superclass. It enables methods to behave differently based on the object they are called on.

Encapsulation: Encapsulation is the bundling of data and methods that operate on the data within a single unit (class). It helps to hide the internal state of an object and restrict access to it.

Packages: Packages are namespaces that organize classes and interfaces into logical groups.

Access Modifiers: Access modifiers (public, private, protected, default) control the visibility and accessibility of classes, variables, and methods.

Exception Handling: Java provides exception handling mechanisms (try, catch, finally) to deal with runtime errors and exceptional situations.

Garbage Collection: Java's garbage collector automatically manages memory by reclaiming unused objects, freeing developers from managing memory explicitly.

Java Standard Library (Java API): Java comes with a rich set of pre-built classes and interfaces in its Standard Library (Java API), providing ready-to-use functionality for common tasks.

Java Development Kit (JDK): JDK is a software development kit used to develop Java applications. It includes the Java Runtime Environment (JRE), compiler, debugger, and other tools.

Integrated Development Environments (IDEs): IDEs like Eclipse, IntelliJ IDEA, and NetBeans provide tools and features to streamline Java development, including code editing, debugging, and project management.

Subclass : A subclass is also known as a derived class or a child class. A subclass is a class that inherits attributes and behaviors (fields and methods) from another class called its superclass or parent class. The subclass can extend the functionality of its superclass by adding new methods and fields or by overriding existing methods. It can also have its own unique methods and fields.

Last updated