Zeek_88 & 89_Collections Framework and Hierarchy (Starting Advanced Java)
STARTING ADVANCED JAVA
COLLECTIONS FRAMEWORK
--> The Collection in Java is a framework that provides an architecture to store and manipulate the group of objects.
--> Java Collections can achieve all the operations that you perform on a data such as searching, sorting, insertion, manipulation, and deletion.
--> Java Collection means a single unit of objects.
--> Java Collection framework provides many interfaces (Set, List, Queue, Deque) and classes (ArrayList, Vector, LinkedList, PriorityQueue, HashSet, LinkedHashSet, TreeSet).
Why do we need collections ?
We need collections for efficient storage and better manipulation of data in java
For ex: we use arrays to store integers but what if we want to
- Resize this array?
- Insert an element in between?
- Delete an elements in Array?
- Apply certain operations to change this array?
How are collections available?
Collections in java are available as class and interfaces Folling are few commonly used collections in java :
- ArrayList -> For variables size collections
- ............................................................................................
- Set -> For distinct collection
- ...........................................................................................
- Stack-> A LIFO data structure
- ............................................................................................
- HashMap -> For strong key - value pairs
Collections class is available in java util package collection class also provides static methods for sorting , searching etc.
Collections in java are available as class and interfaces Folling are few commonly used collections in java :
- ArrayList -> For variables size collections
- ............................................................................................
- Set -> For distinct collection
- ...........................................................................................
- Stack-> A LIFO data structure
- ............................................................................................
- HashMap -> For strong key - value pairs
Collections class is available in java util package collection class also provides static methods for sorting , searching etc.
Hierarchy of Collection Framework
Let us see the hierarchy of Collection framework. The java.util package contains all the classes and interfaces for the Collection framework
Let us see the hierarchy of Collection framework. The java.util package contains all the classes and interfaces for the Collection framework

Comments
Post a Comment