Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within Java in General
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
Java in General
I want to iterate all elements in vector and store it in another vector..?
hariharan jayaprakash
Ranch Hand
Posts: 76
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
I want to iterate all elements in vector and store it in another vector.. how can i achieve tat?
hariharan jayaprakash
Ranch Hand
Posts: 76
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
In my vector elements contains are objects(element objects are own class created objects)..
like i created a class (ProductDTO,ProductDAO,ProductVO) so in my vector contains any of these type of objects elements....
So, i want to iterate this vector and again i need to add it into another vector...
hope am clear with my que...
Stephan van Hulst
Saloon Keeper
Posts: 15484
363
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Use an ArrayList instead of Vector. Vectors are deprecated.
If you want to iterate over a List, use the enhanced for loop. If you want to add all the elements to another collection, use the addAll() method of that collection.
hariharan jayaprakash
Ranch Hand
Posts: 76
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
yeah its workin now.. but i need to use vector only... addAll() method, i got my scenario...
Thanks
In the renaissance, how big were the dinosaurs? Did you have tiny ads?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
How to Store Vector in a table?
how to get data from a db into an array?
copy from one enumeration into another!!
plz help me in this class question
Convert Vector to Method
More...