Also, because Vector has been around before the Collections Framework and the List interface were created, it has several methods that you shouldn't use anymore. For instance, use get instead of elementAt, and use add instead of addElement.
hi As Vector methods are synchronized , there is little more overhead need for thread operation like locking the object and releasing the lock. if a element is to added in Vector v , the current thread must get a lock on the vector v and it must release after adding the value. consider you are doing a single threaded where only one thread will access at a time , adding elements to the vector will bring additional thread- overheads which are not necessary, so ArrayList can be used instead of Vector. But in a multi threaded application , where only one thread need to access your data at a given point of time , you can use Vector
Vector was the oldest Collection. The ArrayList was introduced mainly due to the performance issues faced in using the Vector. Hashtable is the oldest Collection. The Hashtable methods are synchronized and it does not allow null values/keys . HashMap is simmilar to Hashtable , but its methods are not synchronized and it allows one null key and multiple null values.
Both Hashtable and HashMap implments the Map interface.
Both ArrayList and vector Implements List interface.
Another important tip
List , Map and Queue interfaces extend the Collection interface but Map interface does not extends the Collection interface
if your list gets accessed by more than one thread
If you are using JDK 1.5 + then
The �java.util.concurrent� package also has classes like CopyOnWriteArrayList and CopyOnWriteArraySet, which gives you thread safety with the added benefit of immutability to deal with data that changes infrequently. The CopyOnWriteArrayList behaves much like the ArrayList class, except that when the list is modified, instead of modifying the underlying array, a new array is created and the old array is discarded. This means that when a caller gets an iterator (i.e. copyOnWriteArrayListRef.iterator() ), which internally holds a reference to the underlying CopyOnWriteArrayList object�s array, which is immutable and therefore can be used for traversal without requiring either synchronization on the list copyOnWriteArrayListRef or need to clone() the copyOnWriteArrayListRef list before traversal (i.e. there is no risk of concurrent modification) and also offers better performance.