Hari Hara Kumar wrote:I might wrongly understood the question.
Could any one explain what happens behind the screen? I know its a silly question but i am bit confused here.
The best thing is probably to look at the docs for ArrayList, because right at the top it shows you the hierarchy:
java.lang.Object → java.util.AbstractCollection → java.util.AbstractList → java.util.ArrayList
The reason for this is that each level "fills in the blanks" for certain methods, providing them with default implementations.
It should also be noted that ArrayList is NOT
final, so you can extend it to create a class of your own if you want; probably pointless, but it
can be done.
Winston