Java / Interface
Can an interface inherit/extend multiple interface?
Yes.
package com.tutorials.interfaceExample; public interface MyInterface extends ParentInterface1, ParentInterface2 { void method(); } class ImplementingClass implements MyInterface { @Override public void method() { System.out.println("HI"); } } interface ParentInterface1 { void method(); } interface ParentInterface2 { void method(); }
More Related questions...