You are on page 1of 2

c 

Ê Resizable-array implementation of the List interface. A Mc  is used to store


an ³ordered´ group of elements where duplicates are allowed.
Ê mplements all optional list operations, and permits all elements, including null.
Ê 3his class is similar to Vector, except that it is unsynchronized.
Ê 3he size, isEmpty, get, set, iterator, and listterator operations run in constant time.
ArrayList¶s give great performance on get() and set() methods, but do not perform well
on add() and remove() methods when compared to a LinkedList.
Ê An ArrayList capacity is the size of the array used to store the elements in the list. As
elements are added to an ArrayList, its capacity grows automatically. t is an Array based
implementation where elements of the List can be accessed directly through get()
method.

3 

Ê 3his class implements the Set interface and guarantees that the sorted set will be in
ascending element order, sorted according to the natural order of the elements or by the
comparator provided at set creation time, depending on which constructor is used.
Ê 3his implementation not synchronized provides guaranteed log(n) time cost for the basic
operations (add, remove and contains).




Ê 3he M
 class does not guarantee that the order will remain constant over
time.
Ê 3his implementation provides constant-time performance for the basic operations (get
and put), assuming the hash function disperses the elements properly among the buckets.
Ê 3he HashMap implementation is not synchronized. f multiple threads access this map
concurrently, and at least one of the threads modifies the map structurally, it must be
synchronized externally.

J  

Ê 3he J   implements a growable array of objects where the size of the vector can
grow or shrink as needed dynamically.
Ê Like an array, it contains components that can be accessed using an integer index.
Ê An application can increase the capacity of a vector before inserting a large number of
components; this reduces the amount of incremental reallocation.

  

Ê Hash3able is synchronized.
Ê terator in the HashMap is fail-safe while the enumerator for the Hashtable isn¶t.
Ê Hashtable doesn¶t allow nulls
  

Ê 3he HashSet class implements the Set interface.


Ê t makes no guarantee that the order of elements will remain constant over time.
Ê 3his class is not synchronized and permits a null element.

Ê Ê 3his class offers constant time performance for the basic operations (add, remove,
contains and size), assuming the hash function disperses the elements properly among the
buckets.

You might also like