netscape.ldap.util
Class LDAPFilterList

java.lang.Object
  extended by netscape.ldap.util.LDAPFilterList
All Implemented Interfaces:
java.util.Enumeration

public class LDAPFilterList
extends java.lang.Object
implements java.util.Enumeration

The list of LDAPFilter objects returned from a LDAPFilterDescriptor Object. Note that this is an enumeration, so if multiple iterations are needed, save the results.

Version:
1.0
See Also:
LDAPFilterDescriptor, LDAPFilter

Constructor Summary
LDAPFilterList()
          Constructs an LDAPFilterList object.
 
Method Summary
(package private)  void add(LDAPFilter filter)
          Add an LDAPFilter to the private vector.
 boolean hasMoreElements()
          Returns true if there are any LDAPFilter objects to returned.
 LDAPFilter next()
          Returns the next LDAPFilter
 java.lang.Object nextElement()
          Returns the next LDAPFilter as an Object.
 int numFilters()
          Return the number of filters in the filter list.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LDAPFilterList

public LDAPFilterList()
Constructs an LDAPFilterList object. This methos shouldn't need to be called by the developer directly. Construction of the LDAPFilterList object should take place when the Prepare function of LDAPFilterDescriptor is called.

Method Detail

add

void add(LDAPFilter filter)
Add an LDAPFilter to the private vector. Since the filter we're being passed has already been cloned from the master LDAPFilterDescriptor set, all we have to do is add it to the list.


hasMoreElements

public boolean hasMoreElements()
Returns true if there are any LDAPFilter objects to returned.

Specified by:
hasMoreElements in interface java.util.Enumeration

nextElement

public java.lang.Object nextElement()
Returns the next LDAPFilter as an Object. Note: the preferred way to return the next LDAPFilter is to call next()

Specified by:
nextElement in interface java.util.Enumeration
Returns:
The next LDAPFilter object (as an instance of Object)
See Also:
next()

next

public LDAPFilter next()
Returns the next LDAPFilter

Returns:
The next LDAPFilter

numFilters

public int numFilters()
Return the number of filters in the filter list. Note that this number decreases every time next() or nextElement() is called because the elements are removed as they're returned.