|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.jndi.ldap.obj.GroupOfNames.Members
class GroupOfNames.Members
The members of a static group.
Field Summary | |
---|---|
private boolean |
expandSubgroups
|
private javax.naming.NamingEnumeration |
memberDNs
|
private javax.naming.NamingEnumeration |
subgroupMembers
|
private java.util.ArrayList |
subgroups
|
Constructor Summary | |
---|---|
GroupOfNames.Members()
|
|
GroupOfNames.Members(javax.naming.NamingEnumeration memberDNs)
|
Method Summary | |
---|---|
void |
close()
Closes the enumeration and releases its resources. |
private javax.naming.directory.DirContext |
getRootContext()
|
boolean |
hasMore()
Check if the group has more members. |
boolean |
hasMoreElements()
Check if the group has more members. |
java.lang.Object |
next()
Retrieve the next member of the group. |
java.lang.Object |
nextElement()
Retrieve the next member of the group. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private javax.naming.NamingEnumeration memberDNs
private boolean expandSubgroups
private java.util.ArrayList subgroups
private javax.naming.NamingEnumeration subgroupMembers
Constructor Detail |
---|
GroupOfNames.Members()
GroupOfNames.Members(javax.naming.NamingEnumeration memberDNs)
Method Detail |
---|
public boolean hasMoreElements()
hasMoreElements
in interface java.util.Enumeration
public boolean hasMore() throws javax.naming.NamingException
hasMore
in interface javax.naming.NamingEnumeration
javax.naming.NamingException
- If a problem is encountered while checking
whether the group has any more members.public java.lang.Object nextElement()
Group
.
Note that in order to determine whether a member is itself a group
this method reads each member's LDAP entry. As this is potentially an
expensive activity the feature may be disabled by setting the
environment property
"com.sun.jndi.ldap.obj.expandGroup"
to the string value "false". When the feature is
disabled then an object of class Principal
is returned. By default, the feature is enabled.
nextElement
in interface java.util.Enumeration
LdapGroupFactory
object factory is active
then an object of class
Principal
or
Group
is returned.
However, when additional object factories are active then an
object of a different class may be returned.
java.util.NoSuchElementException
- If no more members exist or if a
NamingException
was encountered while
retrieving the next element.public java.lang.Object next() throws javax.naming.NamingException
Group
.
Note that in order to determine whether a member is itself a group
this method reads each member's LDAP entry. As this is potentially an
expensive activity the feature may be disabled by setting the
environment property
"com.sun.jndi.ldap.obj.expandGroup"
to the string value "false". When the feature is
disabled then an object of class Principal
is returned. By default, the feature is enabled.
next
in interface javax.naming.NamingEnumeration
LdapGroupFactory
object factory is active
then an object of class
Principal
or
Group
is returned.
However, when additional object factories are active then an
object of a different class may be returned.
javax.naming.NamingException
- If a problem is encountered while retrieving the
next member of the group.
java.util.NoSuchElementException
- If no more members exist.public void close() throws javax.naming.NamingException
close
in interface javax.naming.NamingEnumeration
javax.naming.NamingException
- If a problem is encountered while
closing the enumeration.private javax.naming.directory.DirContext getRootContext() throws javax.naming.NamingException
javax.naming.NamingException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |