© Vaskaran Sarcar 2020
V. SarcarInteractive Object-Oriented Programming in Javahttps://doi.org/10.1007/978-1-4842-5404-2_6

6. Abstract Classes and Interfaces: The True Art in OOP

Vaskaran Sarcar1 
(1)
Bangalore, Karnataka, India
 

In the previous chapter, you learned that method overriding can help you to achieve runtime polymorphism. In this chapter, you will further explore the concept with two powerful techniques—abstract classes and interfaces. In addition to this, you will also learn how interfaces can help you to implement the concept of multiple inheritance in Java. Once you master these concepts, you can make your program super flexible. Let’s start with abstract classes.

Abstract Classes

Sometimes you start a work, but you may not complete it, ...

Get Interactive Object-Oriented Programming in Java: Learn and Test Your Programming Skills now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.