Interfaces vs Abstract Classes

This lesson compares and constrasts interfaces and abstract classes.

We'll cover the following...

Notes on Interfaces vs Abstract Classes

  1. Interface should be preferred over abstract classes for the following reasons:

    • Existing classes can easily implement new interfaces for added functionality, however existing classes that already extend super classes can't inherit from a new class since multiple inheritance is prohibited in Java.

    • Interfaces can be used for mixin types. A ...