This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
This is what your loop seems to be doing.....
UJList.size() should be 3, since you are adding 3 items. On first iteration, i=0, so you are printing
That should pretty much print all your items in the vector. Why use a loop then? Also, for next iteration, i becomes 3, and it should exit the loop since condition is i<3
are you sure your loop is doing what you wanted it to do?
Also, what is the object rs ?? There is no mention of it here. If there is a problem with rs, the vector may not get populated at all, and throw NullPointerException