Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Disadvantage of using Vectors

 
B Mampilli
Ranch Hand
Posts: 61
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using vectors to store results retrieved by servlets from the database. These vectors are then used by JSP's to display on the html page. Is there any disadvantage of using vectors? Should Hashtables be used instead of Vectors?
Boney
 
Amol Desai
Ranch Hand
Posts: 82
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
You could use arraylist instead.
ArrayList are faster than vectors since they are unsynchronised.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic