Arraylist vs. Vector

Arraylist vs. Vector.

ArraylistVector
Arraylist's methods are not synchronized which means they are not thread safe.Vector's methods are synchronized which means they are thread safe.
It is not a legacy class.It is a legacy class.
It is fast because it is non-synchronized.It is slow because it is synchronized.
It uses an iterator interface to traverse the elements.It uses an enumeration interface to traverse the elements, but it can also used iterator interface.
It increases 50% in its capacity.It increases 100% in its capacity.
What is a Throwable class?
What is a Throwable class? - It is the superclass of all errors and exceptions in Java....
Significance of Finalize method
Significance of Finalize method - The Finalize method of an object is called when GC is about to clean up the object. We can keep clean up....
Significance of Finalize method
Significance of Finalize method - The Finalize method of an object is called when GC is about to clean up the object. We can keep clean up......
Post your comment