class Base
{
static class Inner
{
public static void main(
String[] args)
{
System.out.println("Inner");
}
}
}
public class MainTest extends Base.Inner
{
}
this code was posted and it is fine. Question here is in a different context.
Here the class Inner is actually a TopLevel class. IF this class were a pure inner class instead then how would we extend the MainTest class ?
surely "class MainTest extends Base.Inner" would not work. Then what would be correct way ?