The Collections Framework
1. The basic requirement of any application program is storing, structuring and retrieving instances of objects.
2. The Collections framework provides modes of storing, structuring and retrieving of object instances . The Collections framework implements a family of containers for holding instances of objects.
3. Java provides one language construct, arrays, for implementation of storage, structuring and accessing of object instances (elements). Why do we need the Collections framework.
* An array can store only a single element type.
* An array is static. The number of instances to be stored must be specified in advance.
* An array has a fixed addressing pattern.
* Traversal must be procedurally programmed.
* Storage and retrieval from arrays is very efficient.
* Index based addressing is an appropriate abstraction for regular structures.