Regards
SaurabhSri (SCJP 1.5)
Regards
SaurabhSri (SCJP 1.5)
Author of <a href="http://www.newsinjector.com" target="_blank" rel="nofollow">NewsInjector</a>
Betty Rubble? Well, I would go with Betty... but I'd be thinking of Wilma.
The only problem with that approach is that one of the Maps will have only "start" and "stop" as its keys.Originally posted by Peter Chase:
It sounds like you want a two-way map. There's none in the JDK, but you can easily make one, by combining two HashMaps. One would take the service name as key and status as value, the other would take status as key and name as value. You must make sure that you always add to both maps and remove from both maps.
Regards
SaurabhSri (SCJP 1.5)
Originally posted by Peter Chase:
It sounds like you want a two-way map. There's none in the JDK, but you can easily make one, by combining two HashMaps.
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Originally posted by Ilja Preuss:
Or simply use an existing open source implementation: http://commons.apache.org/collections/api-3.1/org/apache/commons/collections/BidiMap.html
You ought to ventilate your mind and let the cobwebs out of it. Use this cup to catch the tiny ads:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
|