Java OOP: Multi-level Inheritance


Overview/Description
Expected Duration
Lesson Objectives
Course Number
Expertise Level



Overview/Description

In this course, learners will focus on creation of multilevel inheritance in Java and how such hierarchies include child and grand-child classes that all inherit from a common ancestor base class. Begin with an introduction to multilevel inheritance, and how you can access multiple derived classes by using a base class in multilevel inheritance. Explore use of the instanceof operator, where you can check that an object is an instance of every class in its inheritance hierarchy. Concerning the Is-A Relationship, you will learn how to apply multilevel inheritance when every object of the derived class is an object of the base class, but not every object of the base class is an object of the derived class. Examine downcasting; see how to upcast multiple levels; learn why downcasting is very dangerous; and perform various upcasting operations. After moving on to multilevel inheritance hierarchies, you will construct two parallel base classes and derived classes for each of those base classes. Finally, explore use of the extends keyword, recognizing situations where multiple inheritance is allowed.



Expected Duration (hours)
0.9

Lesson Objectives

Java OOP: Multi-level Inheritance

  • discover the key concepts covered in this course
  • recognize how you can access multiple derived classes by using a base class in multilevel inheritance
  • use the instanceof operator to check that an object is an instance of every class in its inheritance hierarchy
  • recognize how to apply multilevel inheritance when every object of the derived class is an object of the base class, but not every object of the base class is an object of the derived class
  • recognize how you can upcast multiple levels up and how downcasting is very dangerous
  • perform various casting operations
  • construct two parallel base classes and derived classes for each of those base classes
  • recognize situations where multiple inheritance is not allowed
  • summarize the key concepts covered in this course
  • Course Number:
    it_jdoopjdj_03_enus

    Expertise Level
    Intermediate