Nested Classes: Lesson
Lesson 1 of 1
  1. 1
    Let’s begin by defining what a nested class is! A nested class is a class that can be found within another class. The process of a class being enclosed in another is known as encapsulation. Nes…
  2. 2
    As 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 class…
  3. 3
    Now 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 …
  4. 4
    In this exercise, we will be taking a closer look at static nested classes. First, let’s review the definition of static nested classes. Static nested classes are nested classes that only have acce…
  5. 5
    Now let’s take a look at the concept of shadowing in Java. Shadowing allows for the overlapping scopes of members with the same name and type to exist in both a nested class and the enclosing c…
  6. 6
    You made it! Let’s review what we have learned so far! - There are two main types of nested classes: non-static (also known as inner) nested classes, and static nested classes - Nested class…

What you'll create

Portfolio projects that showcase your new skills

Pro Logo

How you'll master it

Stress-test your knowledge with quizzes that help commit syntax to memory

Pro Logo