For below code,
interface SuperInterface{
void f();
interface StaticNestedInterface{
}
}
class Sub implements SuperInterface{
public void f(){
}
}
public class Dummy {
public static void main(String[] args) {
Sub x = new Sub();
}
}
Compiler does not ask class Sub
to implement interface StaticNestedInterface
.
Is class Sub
a valid java code?