Nested Classes
Learn about nested classes in Java.
StartNested Classes: Lesson
Lesson 1 of 1
- 1Let’s begin by defining what a nested class is! A nested class is a class that can be found within another class. The pr…
- 2As mentioned in the previous exercise, there are two types of nested classes: non-static (also known as inner) nested, and static. Let’s take a closer look at what makes these two types of clas…
- 3Now that we’ve reviewed the main differences between non-static nested and static nested classes, let’s break down how to implement the use of a non-static nested class. For more clarity, from here…
- 4In this exercise, we will explore the concept of static nested classes. A static nested class is a class that belongs to its enclosing class in the same way that a static variable belongs to its …
What you'll create
Portfolio projects that showcase your new skills
How you'll master it
Stress-test your knowledge with quizzes that help commit syntax to memory