Package cronapi.osjava.sj.jndi
Class ContextNames
- java.lang.Object
-
- cronapi.osjava.sj.jndi.ContextBindings
-
- cronapi.osjava.sj.jndi.ContextNames
-
- All Implemented Interfaces:
Enumeration,NamingEnumeration
public class ContextNames extends ContextBindings
This class represents a NamingEnumeration of the class names of a Context. Originally authored by Henri Yandell and modified to make more flexable with other Context implementations.- Version:
- $Rev: 1978 $ $Date: 2005-08-29 18:30:33 -0700 (Mon, 29 Aug 2005) $
- Author:
- Robert M. Zigweid and Henri Yandell
-
-
Constructor Summary
Constructors Constructor Description ContextNames(Map table)Creates a ContextNames object based upon an a Map of names and the objects the names are bound to.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectnext()Returns aNameClassPaircreated from the next available name.ObjectnextElement()Returns aNameClassPaircreated from the next available name.-
Methods inherited from class cronapi.osjava.sj.jndi.ContextBindings
close, hasMore, hasMoreElements
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Enumeration
asIterator
-
-
-
-
Constructor Detail
-
ContextNames
public ContextNames(Map table)
Creates a ContextNames object based upon an a Map of names and the objects the names are bound to. Iftableis modified after instantiation of ContextBindings, behavior is undefined and should be considered invalid.- Parameters:
table- The table upon which the ContextBindings is based.
-
-
Method Detail
-
nextElement
public Object nextElement()
Returns aNameClassPaircreated from the next available name.- Specified by:
nextElementin interfaceEnumeration- Overrides:
nextElementin classContextBindings- Returns:
- a NameClassPair representing the binding of the name and the object bound to the name
-
next
public Object next() throws NamingException
Returns aNameClassPaircreated from the next available name.- Specified by:
nextin interfaceNamingEnumeration- Overrides:
nextin classContextBindings- Returns:
- a NameClassPair representing the binding of the name and the object bound to the name
- Throws:
NamingException- if a naming exception occurs
-
-