An interface that extends multiple interfaces
Below code
interface I3{
boolean abc();
};
interface I2{
void abc();
};
public class Example1 implements I3, I2{
@Override
public void abc() {
//Eclipse IDE picked this unimplemented method with the compiler error
}
}
Is the programmer obligated not to get into this situation?
Why does Java allow interface extending multiple interfaces? when is java already avoiding the similar problem of a class inheriting multiple superclasses?
In the case of such constants inherited from multiple interfaces, interfacename.constantname
the subclass avoids ambiguity.
+3
source to share