|
|
This java tutorial highlight difference between Vector and ArrayList and enable us to take inform decision on where to use vector and where to use arraylist.First and foremost difference is Vector is synchronized and ArrayList is not, what it means is that all the method which structurally modifies Vector e.g. add () or remove () are synchronized which makes it thread-safe and allows it to be used safely in a multi-threaded environment. On the other hand ArrayList methods are not synchronized thus not suitable for use in multi-threaded environment. |
 |
View Tutorial