File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Programmer Certification (SCJP/OCPJP)
enum, Enum, Enumeration, Enumerator, Iterator
Joined: Nov 18, 2006
May 29, 2007 04:29:00
I think that I figured out what is what here.
enum is the new keyword in Java 5 that allows you to implement enumerated types.
Enum is a class in java.lang for which types defined using the enum keyword all all subclasses.
Enumerator is similiar to an Iterator only the Enumerator is an older class.
Iterator is a newer class than Enumeration that allows you to iterate over objects of classes that implement Iterable.
Then there is the new for-each loop in Java 5 that is an alternative to using an object of type Iterator to iteration over an array or an object that implements the Iterable interface.
Is this all right?
Joined: Aug 03, 2002
May 29, 2007 05:04:00
summary of the new Java 5.0 features.
Ask a Meaningful Question
Getting someone to think and try something out is much more useful than just telling them the answer.
subject: enum, Enum, Enumeration, Enumerator, Iterator
[Interview Q] Why does array index begin with 0 instead of 1 ???
Of Enumerators and Iterators
enhanced for loop question
Iterator & Enumeration
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014