 2007 West |
|
GOLD SPONSORS:
|
Active Endpoints Your SOA Needs BPEL for Orchestration
|
BEA Virtualized SOA: Adaptive Infrastructure for Demanding Applications
|
Nexaweb Overcoming Bandwidth Challenges with Nexaweb
|
TIBCO What is Service Virtualization?
|
|
SILVER SPONSORS:
|
WSO2 Using Web Services Technologies and FOSS Solutions
|
|
Click For 2007 East Event Webcasts
|
|
TOP THREE LINKS YOU MUST CLICK ON
Java Industry News
Can Map Do A Better Job at Allowing Optimized Iteration Over Its Keys and Values Together?
I've used the map to store things in a keyed fashion and want to iterate over the keys and the value for each. Problem is, each time I do it I find myself thinking how inefficient it must be. The keys iterator returns the keys so it has to walk the keys, however the get(key) has to lookup the key each time.Internally implementations like HashMap store keys and values as linked list pairs
Reader Feedback : Page 1 of 1
#7 |
Yuri commented on the 2 Sep 2006
Map.entrySet() enough said! |
#6 |
adam commented on the 17 Aug 2006
Please look at the API before complaining that it lacks something. Map.entrySet() has been there since Maps came out. |
#5 |
Ashish commented on the 16 Aug 2006
check out java.util.Map.Entry for (java.util.Iterator iter = map.entrySet().iterator(); iter.hasNext(); ) { java.util.Map.Entry entry = (java.util.Map.Entry) iter.next(); Object key = entry.getKey(); Object value = entry.getValue(); } |
#4 |
snoobabk commented on the 16 Aug 2006
Hi and by the way to everyone my previous post has a little sarcasm in it and there are equally smalltalk zealots, java zealots, python zealots, ruby zealots, lisp zealots etc etc There will always be :) but for people wanting to look at an open Smalltalk platform and other smalltalky things go to: [visit link] , [visit link] , [visit link] |
#3 |
snoobabk commented on the 16 Aug 2006
Hi I'm a long time Java developer but have been moving over to Smalltalk wherever I can. Other people (Java zealots) reading this article may get the wrong impression of Smalltalkers when they read your article because its incorrect. They'll jump all over you and think that Smalltalk is showing its age. A Map does have the ability to return a 'pair' of key-value bindings, it always has. It's an EntrySet that holds a key and value that can be obtained via a call such as map.entrySet(). Cheers |
#2 |
SYS-CON Australia News Desk commented on the 15 Aug 2006
I've used the map to store things in a keyed fashion and want to iterate over the keys and the value for each. Problem is, each time I do it I find myself thinking how inefficient it must be. The keys iterator returns the keys so it has to walk the keys, however the get(key) has to lookup the key each time.Internally implementations like HashMap store keys and values as linked list pairs |
#1 |
JDJ News Desk commented on the 15 Aug 2006
I've used the map to store things in a keyed fashion and want to iterate over the keys and the value for each. Problem is, each time I do it I find myself thinking how inefficient it must be. The keys iterator returns the keys so it has to walk the keys, however the get(key) has to lookup the key each time.Internally implementations like HashMap store keys and values as linked list pairs |
YOUR FEEDBACK  | Is Sun Looking to Replace
CEO Jonathan Schwartz? By Maureen O'Gara Brigdson Smith wrote:
remember, Eric Schmidt
was Schwartz's first boss
at Sun - something tells
me if he left Sun, it'd
take four minutes for him
to end up to Google. |  | What Does the Future Hold
for the Java Language? By Joe Winchester Tommy wrote: I simply do
not agree on many parts:
- .NET has a lot of
traction
- you can
certainly know well (and
master) more than one
language. If you cannot
master more than one
language, this could
potentially be one of
your limits.
- Java is not a perfect
language
- It is ea... |  | i-Technology Opinion: Why
Use Extreme Programming? By Troy Holmes James Nwaba wrote: This
is a nice article - very
straight froward, easy to
understand.However, there
was no mention of any
organization that have
implemented XP.
The author said, "Many of
the concepts found in
this lightweight method
of development have been
implemented into the ... |  | iPhone Office: 100 Ways
to Turn Your Device into
the Ultimate Productivity
Tool By Jessica Merritt QueZZtion wrote: Can the
iPhone really work as a
multimedia remote for
iTunes or even a desktop? |  | DoJa in NTT DoCoMo Phones By Zev Blut Venkat wrote: Excellent
explanation. It will be
helpful if it was in
pictorial form ie with
the emulator images. Can
u please send me the
I-mode to I appli
communication and a brief
explanatioj about the
architecture.Thanks in
advance. |
SUBSCRIBE TO THE WORLD'S MOST POWERFUL NEWSLETTERS
|
SYS-CON FEATURED WHITEPAPERS  | Saving Your Investment:
Transforming J2EE
applications into Web 2.0
using GWT By RIA News Desk The pressure is on to
keep pace with Web 2.0
entrants into the
marketplace. Rewriting is
expensive; | WSRP Really Works! - Part
2 By Matt Silver A standard from OASIS
called Web Services for
Remote Portlets (WSRP) is
used so portlets can be
deco | Adobe's Kevin Lynch and
Microsoft's Scott Guthrie
to Keynote AJAX World RIA
Conference & Expo By RIA News Desk Two of the biggest
launches in Rich Internet
Application history took
place in 2007/2008 when
Adobe | Sun Expects Q4 Earnings
Above Estimates By Java News Desk On Tuesday evening Sun
issued a fourth-quarter
guidance range largely
above analysts'
estimates. The | Virtualization Conference
Keynote Webcast Live on
SYS-CON.TV By James Hamilton Brian Stevens, the Chief
Technology Officer and
Vice President of
Engineering of Red Hat,
delivered | The Beauty of JavaScript By RIA News Desk JavaScript is one of the
most interesting and
misunderstood programming
languages in common use
toda | JavaScript: The Good
Parts By RIA News Desk JavaScript is a language
with more than its share
of bad parts. It went
from non-existence to
global | Use JavaScript 2 Today
with OpenLaszlo By RIA News Desk JavaScript 2 is becoming
increasingly important.
Learn how to take
advantage of JavaScript 2
while s | Server-Side JavaScript -
All the Cool Kids Are
Doing It! By RIA News Desk In this session that no
developer who uses
JavaScript or
ActionScript will want to
miss, delegates w | AJAX with jQuery By RIA News Desk jQuery is a rapidly
growing, popular
JavaScript library. Its
powerful and modular
architecture, whic | Why the Web Dinosaurs
Died By Jonas Jacobi; John Fallows; Ric Smith; Brian Albers A fast-moving Comet is
about to impact the
Internet. When it hits,
it will wipe away the
architectur | Sun Achieves Land Speed
Record: 1M Messages Per
Second By Java News Desk Algorithmic trading
continues to drive the
quest for greater speed
and lower latency in the
capital | AJAX and RIA Technology
Will Be Free for All: Sun
CEO By Java News 'Java's always been a RIA
platform - before the
world really wanted one,'
claimed Sun's CEO
Jonathan | Quest Software's JProbe
Now Available as Eclipse
Plug-In By Eclipse News Desk Quest Software announced
the latest release of its
Java profiler, JProbe
8.0, which is now offered
a | What Does the Future Hold
for the Java Language? By Joe Winchester Before Java I was a
Smalltalk guy. I remember
switching from one
language to the other and
the tippi | White Paper: "Ensuring
Code Quality in
Multi-Threaded
Applications" By Java News Desk Today, the world of
software development is
presented with a new
challenge. To fully
leverage this n | AccuRev and Rally
Software Partner to Scale
Agile Software
Development Best
Practices By SOA World Magazine News Desk AccuRev and Rally
announced a technology
partnership that will
integrate AccuRev
software change and | MyEclipse 6.5: The Maven
Tipping Point for 1
Million Java Developers By Eclipse News Desk Genuitec announced the
availability of MyEclipse
Enterprise Workbench 6.5;
Java's most compelling ID | AccuRev Leverages Web 2.0
Technology to Extend
Process Management Reach
Across the Organization By Web 2.0 News Desk AccuRev announced a new
AJAX-based Web Interface
and a native integration
with Microsoft Windows
Exp | Voyager Offers Android,
.NET CF, Java Runtime
Support By Wireless News Desk Recursion Software
released a private beta
version of their Voyager
mobile platform, with
powerful i |
SPONSORED BY INFRAGISTICS
|