| Java FAQ | ||
| JSP FAQ | ||
| Servlet FAQ | ||
XyzWs Java FAQ:
What are the differences between Vector and ArrayList? Which one is better?
Printer-friendly version |
Mail this to a friend
|
Advertisement
|
What are the differences between Vector and ArrayList? Which one is better?
ArrayList is part of the Java collection framework. You should use it in most time to take advantages of Java collection framework. You probably won't need synchronization in most cases. It is easy enough to create a synchronized ArrayList using the following code: Collections.synchronizedList(new ArrayList());
Notice: From ArrayList API Document:
|