Java Collections enumeration() MethodThe enumeration() is a method of Java Collections class which is used to get the enumeration over the specified collection. SyntaxFollowing is the declaration of enumeration() method: Parameter
ReturnsThe enumeration() method returns the enumeration over the specified collection. ExceptionsNA Compatibility VersionJava 1.5 and above Example 1Test it NowOutput: The Enumeration List are: JAVA JSP SERVLET C PHP PERL Example 2Test it NowOutput: The Enumeration List are: 1100 2100 5100 Example 3Test it NowOutput: Elements using Enumeration: 101 Hello World true 101.5
Next TopicJava Collections Class
|