The basic purpose of these interfaces is to allow collections to be manipulated independently of the details of their representation. The core collection interfaces are the heart and soul of the collections framework. When you understand how to use these interfaces, you know most of what there is to know about the framework. To keep the number of core collection interfaces manageable, the JDK doesn't provide separate interfaces for each variant of each collection type. If an unsupported operation is invoked, a collection throws an UnsupportedOperationException .
Implementations are responsible for documenting which of the optional operations they support.
All of the JDK's general purpose implementations support all of the optional operations. The four sections that follow teach you how to use each of the four basic core collection interfaces. In particular, they describe the idioms that allow you to use these interfaces effectively. Collection The Collection interface is the root of the collection hierarchy. A Collection represents a group of objects, known as its elements .