[jdom-interest] Re: New realease, Text class... Arghh

Bradley S. Huffman hip at a.cs.okstate.edu
Wed Jan 9 19:14:33 PST 2002


Dennis Sosnoski writes:

> Using indexed lookup is not necessarily a good idea with the (beta) 
> released version of JDOM. This code returns a linked list (PartialList), 
> so indexing can get very expensive - it requires chaining through the 
> list on every access. If you *know* you're working with an ArrayList or 
> equivalent indexing through the elements is great. Otherwise it's safer 
> to use an Iterator, especially since object creation overhead is pretty 
> low for Hot Spot JVMs.

Damn, your right. My apologies, I should have caught that :)

Brad



More information about the jdom-interest mailing list