RTFJD (the JavaDocs are your friends!) If you haven't read them in a long time, then RRTFJD (they might have changed!)
I think they would be blaming it unfairly. I think the Iterator documentation clearly says only to use the Iterator's methods to add or remove elements. The exception is called “concurrent” not because different threads are causing a problem, but because a change has occurred concurrently with the iteration of the List.Jesse Silverman wrote:. . . many would blame Iterator interface for being confusing. . . .
RTFJD (the JavaDocs are your friends!) If you haven't read them in a long time, then RRTFJD (they might have changed!)
We usually do agree . . . eventually.Jesse Silverman wrote:I'm going to agree with you Campbell . . .
The JLS (=Java® Language Specification) is very clear about that. The Java™ Tutorials keep quiet about that.mention that [for‑each] is just hiding the iterator for us.
Agree (sorryA better presentation would be that the enhanced for is fine for looking at one element at a time and doing something based on that.
Please explain more; I have never got my act together to learn about spliterators.. . . Spliterator was described as doing Iterators right, . . . .
RTFJD (the JavaDocs are your friends!) If you haven't read them in a long time, then RRTFJD (they might have changed!)