Monday, May 22, 2006

Static Inner Class

Outer out = new Outer();
Outer.non_static ns = out.new non_static();
Outer.inner in = new Outer.inner();

where,
Outer --> Outer class
non_static --> inner non static class
inner --> inner static class
For calling non static inner class we require the instance of the outer class and for calling static innner class doesn't require the instance of the outer class.