Variations of Inner Classes
In this series following combinations are discussed. 1. Java Nested Classes 2. Static Nested Classes 3. Nested Interfaces 4. Interface inside Interface 5. Nested Interface within Class 6. Class inside Interface
In this series following combinations are discussed. 1. Java Nested Classes 2. Static Nested Classes 3. Nested Interfaces 4. Interface inside Interface 5. Nested Interface within Class 6. Class inside Interface
Like a class you have seen, an interface can be nested within a) a class or b) another interface. That is, an interface can be declared inside a class body or interface body. That is, an interface can declare within it, classes, interfaces, instance variables and abstract methods. Let us see one by one. 1. …