org.objectweb.carol.util.naming
Class LocalEnumeration

java.lang.Object
  extended by org.objectweb.carol.util.naming.LocalEnumeration
All Implemented Interfaces:
java.util.Enumeration, javax.naming.NamingEnumeration

public class LocalEnumeration
extends java.lang.Object
implements javax.naming.NamingEnumeration

Local enumeration for local context

Author:
Florent Benoit (Refactoring)

Constructor Summary
LocalEnumeration(javax.naming.Context ctx, java.lang.String[] names)
          Default constructor
 
Method Summary
 void close()
          Close the enumeration
 boolean hasMore()
          Enumeration is finished ?
 boolean hasMoreElements()
          Enumeration is finished ?
 java.lang.Object next()
           
 java.lang.Object nextElement()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalEnumeration

public LocalEnumeration(javax.naming.Context ctx,
                        java.lang.String[] names)
Default constructor

Parameters:
ctx - given context
names - names to enumerate
Method Detail

hasMore

public boolean hasMore()
Enumeration is finished ?

Specified by:
hasMore in interface javax.naming.NamingEnumeration
Returns:
true is this is finished

next

public java.lang.Object next()
                      throws javax.naming.NamingException
Specified by:
next in interface javax.naming.NamingEnumeration
Returns:
Next object of the enumeration
Throws:
javax.naming.NamingException - if compositeName object cannot be built

hasMoreElements

public boolean hasMoreElements()
Enumeration is finished ?

Specified by:
hasMoreElements in interface java.util.Enumeration
Returns:
true is this is finished

nextElement

public java.lang.Object nextElement()
Specified by:
nextElement in interface java.util.Enumeration
Returns:
Next object of the enumeration

close

public void close()
Close the enumeration

Specified by:
close in interface javax.naming.NamingEnumeration