Skip to content
UPEEC

Core Java

The language itself — compilation, types, strings, methods, packages, modifiers, enums, records, annotations and nested classes. JDK/JRE/JVM, Java basics and exception handling have their own pages earlier in this subject.

Beginner
Comments 0

This is an overview — pick a sub-topic below.

Sub-topics (21)

Variables in Java

Typed named storage: local, instance (fields) and static (class) variables.

Beginner♥ 0🔖 0💬 0

Primitive Types

Eight built-in value types: `byte`, `short`, `int`, `long`, `float`, `double`, `char`, `boolean`.

Beginner♥ 0🔖 0💬 0

Reference Types

Variables of class, interface and array types hold references to objects on the heap.

Easy♥ 0🔖 0💬 0

Operators in Java

Arithmetic, relational, logical, bitwise, shift (`>>`, `>>>`), assignment, ternary and `instanceof`.

Beginner♥ 0🔖 0💬 0

Control Flow in Java

`if`/`else`, `switch`, `for`, enhanced `for`, `while`, `do-while`, `break`, `continue`.

Beginner♥ 0🔖 0💬 0

Arrays in Java

Fixed-size, typed, zero-indexed objects with a `length` field and bounds checking.

Beginner♥ 0🔖 0💬 0

Strings in Java

Immutable sequences of characters with many methods.

Beginner♥ 0🔖 0💬 0

StringBuilder

A mutable string buffer for efficient concatenation in loops.

Beginner♥ 0🔖 0💬 0

Methods

Functions defined in classes: return type, name, parameters, body.

Beginner♥ 0🔖 0💬 0

Varargs

Accept a variable number of arguments as an array.

Easy♥ 0🔖 0💬 0

Packages

Namespaces that organise classes, matching the folder structure.

Beginner♥ 0🔖 0💬 0

Imports

Bring classes from other packages into scope.

Beginner♥ 0🔖 0💬 0

Access Modifiers

Control visibility: `public`, `protected`, package-private (no keyword) and `private`.

Beginner♥ 0🔖 0💬 0

Enums in Java

Type-safe sets of constants that can have fields, constructors and methods.

Easy♥ 0🔖 0💬 0

Records

Concise immutable data classes (Java 16+) with constructor, accessors, `equals`, `hashCode` and `toString` generated.

Easy♥ 0🔖 0💬 0

Annotations

Metadata on code: `@Override`, `@Deprecated`, `@FunctionalInterface`, and framework annotations like `@Test` or `@GetMapping`.

Easy♥ 0🔖 0💬 0

Nested Classes

Classes declared inside another class; static nested classes don't need an outer instance.

Easy♥ 0🔖 0💬 0

Inner Classes

Non-static nested, local and anonymous classes that can access the outer instance.

Intermediate♥ 0🔖 0💬 0

Assertions

`assert condition : "message";` checks assumptions during development.

Easy♥ 0🔖 0💬 0

Spotted a mistake or want to add detail? Suggest an improvement — Content Contributors' edits are reviewed by editors before they go live.

Discussion (0)

Sign in or join free to ask questions and discuss this topic.