Can any tell me the difference between Iterator ane Enumeration? Pls explain with eg..
Post by:Freddy Wong
, Ranch Hand
I don't think this is a question that should be asked in the advanced forum. Anyway, Iterator allows you remove the item, Enumeration doesn't. Basically, Iterator can do whatever the Enumeration can.
Post by:Jesper de Jong
Enumeration is part of the old Java collections API (from Java 1.1 and older). In Java version 1.2, the new collections framework was added. Iterator is part of the new collections framework. The old classes like Enumeration, Vector and Hashtable were not removed to ensure backwards compatibility.