File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Java SE 8 for the Really Impatient
this week in the
List to HashMap?
Joined: Jan 04, 2001
Oct 13, 2008 09:16:00
I have a method which presently returns a List.
Now my method needs to return (account, status) instead of just account.
I am thinking I need to change the method to return hashmap instead of list.
Can anyone suggest me better solution?
Joined: Oct 13, 2005
Oct 13, 2008 09:47:00
Sounds like a beginner's question . . .
Can you incorporate status and account into a single object?
Joined: Aug 05, 2005
Oct 13, 2008 09:48:00
What sort of object is account ? Can you not add a status field to it ?
I agree. Here's the link:
subject: List to HashMap?
Would a HashSet be a way to solve this problem?
Generics Implementation in Java SE 5
search for a value within list of HashMaps
Too many methods
PMD: LooseCouplingRule, what does this REALLY mean?
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014