This feature is avaialble in java 8, it is called default method or defender method.
Default methods enable you to add new functionality to the interfaces of your libraries and ensure binary compatibility with code written for older versions of those interfaces.
Find more about default method here.
java 8 snapshoot version is available jdk8 Build b129 .
There is one common question that people ask about default methods when they hear about the new feature for the first time: "What if the class implements two interfaces and both those interfaces define a default method with the same signature?".
but it is handled during compile time, get more explanation with example Here