Multiple Inheritance in Java 8 through Interface

Multiple Inheritance in Java is nothing but one class extending more than one class. Previous versions of Java(until JDk 7) doesn’t support Multiple Inheritance because it causes a famous problem called Diamond Problem and hence indirectly Multiple Inheritance in Java is achieved using Interfaces. After the introduction of Default Methods in Java 8, even the interfaces can also have the method bodies. In this tutorial let’s see how the Diamond Problem is prevented in Java 8. [Read more…]