A Collection is a group of objects represented as a single unit and which defines several classes and interfaces. Collection framework is very important topic for java interview questions, you can read usage, difference and advantages of all interfaces and classes .
In the current post, we will discuss collection hierarchy.
All classes and interfaces related to Collection Framework are in java.util package. Collection interface is at the top of class hierarchy of Collection Framework as shown in below diagram.
Below diagram shows the class hierarchy of collection framework.
The Collection Framework is divided into four interfaces(three interfaces inherits Collection interface, but map interface is not inherits Collection interface, this is a separate interface ).
Related Posts:--
1) Collection Interview Questions and Answers in Java
2) How to iterate the TreeMap in reverse order in Java
3) How to Remove duplicates from ArrayList in Java
4) Internal Implementation of TreeMap in Java
5) Internal implementation of ArrayList in Java
6) Internal Implementation of LinkedList in Java
In the current post, we will discuss collection hierarchy.
All classes and interfaces related to Collection Framework are in java.util package. Collection interface is at the top of class hierarchy of Collection Framework as shown in below diagram.
Below diagram shows the class hierarchy of collection framework.
Collection Hierarchy in Java |
The Collection Framework is divided into four interfaces(three interfaces inherits Collection interface, but map interface is not inherits Collection interface, this is a separate interface ).
- List
- Queue
- Set
- Map
Related Posts:--
1) Collection Interview Questions and Answers in Java
2) How to iterate the TreeMap in reverse order in Java
3) How to Remove duplicates from ArrayList in Java
4) Internal Implementation of TreeMap in Java
5) Internal implementation of ArrayList in Java
6) Internal Implementation of LinkedList in Java
No comments:
Post a Comment