#include <java_util_Enumeration.h>
Inheritance diagram for java::util::Enumeration:


Public Types | |
| enum | { xmogDefaultFlags = xmog_base::GLOBAL, xmogMajorVersion = 3, xmogMinorVersion = 2, xmogPatchVersion = 9, xmogBuildNumber = 2047 } |
|
typedef ::xmog_java_array_template< ::java::util::Enumeration > | array1D |
|
typedef ::xmog_java_array_template< ::xmog_java_array_template< ::java::util::Enumeration > > | array2D |
Public Member Functions | |
| virtual bool | hasMoreElements (::xmog_localenv *p_xenv=NULL, xmog_flags f_xflags=xmogDefaultFlags) |
| Tests if this enumeration contains more elements. | |
| virtual ::java::lang::Object | nextElement (::xmog_localenv *p_xenv=NULL, xmog_flags f_xflags=xmogDefaultFlags) |
| Returns the next element of this enumeration if this enumeration object has at least one more element to provide. | |
Successive calls to the nextElement method return successive elements of the series.
For example, to print all elements of a vector v: <blockquote>
for (Enumeration e = v.elements() ; e.hasMoreElements() ;) {
System.out.println(e.nextElement());<br>
}
</blockquote>
Methods are provided to enumerate through the elements of a vector, the keys of a hashtable, and the values in a hashtable. Enumerations are also used to specify the input streams to a SequenceInputStream.
NOTE: The functionality of this interface is duplicated by the Iterator interface. In addition, Iterator adds an optional remove operation, and has shorter method names. New implementations should consider using Iterator in preference to Enumeration.
|
||||||||||||
|
Tests if this enumeration contains more elements.
|
|
||||||||||||
|
Returns the next element of this enumeration if this enumeration object has at least one more element to provide.
|
1.4.1