I've been reading a few articles about the new Java 8 features. With the introduction of Extension Methods i.e. methods that are prefixed with the default keyword and provide an implementation.
I checked a couple of questions here where people have asked about the differences in abstract classes and interfaces like the one here and here and the biggest difference seems to be that abstract classes allowed you to specify default implementations.
Does this mean that the difference between Abstract Classes and Interfaces is largely cosmetic and given the fact that a class can implement multiple interfaces; they give more flexibility in both design and implementation.
I can see that abstract classes are here to stay, primarily for being backward compatible with older code. Would I be right in not using Abstract Classes going forward and use Interfaces only? If not could you provide an example, just having some fields defined in the abstract class doesn't count. I'm looking for a compelling use case where Abstract Classes are still a better fit when compared to Interfaces.
On the flip side the purists would argue that the default implementations pollute the interfaces which should only specify the contract and the behavior should always be in the Concrete classes(A part of the behavior could be in abstract classes). Is there any merit to this argument?