Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Sorting hashtable in j2me

 
Dushyant Chhetri
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

How can I sort a hashtable in J2ME? There is no comparator that can be used.

 
Tim Holloway
Saloon Keeper
Pie
Posts: 18009
47
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can't actually sort a hashtable - a hashtable is not a linear structure. However you can create a list of entries contained in a hashtable and sort the list. You just have to do it the old-fashioned way and code it all yourself.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic