hi all, is there any limitation in layer of innerclass we could make inside a class? thanks.
posted 13 years ago
Not really. It's possible there's some fundamental limitation based on memory limitations or class file formats, similar to the way a String can never have more than Integer.MAX_VALUE chars in it. But practically speaking, you can nest as deep as you want. The limiting factor will probably be that someone may shoot you for writing unreadable code if your nesting gets too deep.