edu.vt.middleware.ldap.bean
T - type of backing mappublic abstract class AbstractLdapResult<T extends java.util.Map<java.lang.String,LdapEntry>> extends AbstractLdapBean implements LdapResult
AbstractLdapResult provides a base implementation of
LdapResult where the underlying entries are backed by a
Map.| Modifier and Type | Field and Description |
|---|---|
protected T |
entries
Entries contained in this result.
|
protected static int |
HASH_CODE_SEED
hash code seed.
|
beanFactory, logger| Constructor and Description |
|---|
AbstractLdapResult(LdapBeanFactory lbf)
Creates a new
AbstractLdapResult with the supplied ldap bean
factory. |
| Modifier and Type | Method and Description |
|---|---|
void |
addEntries(java.util.Collection<LdapEntry> c)
This adds a
Collection of entries to this
LdapResult. |
void |
addEntries(java.util.Iterator<javax.naming.directory.SearchResult> i)
This adds an
Iterator of SearchResult to this
LdapResult. |
void |
addEntries(javax.naming.NamingEnumeration<javax.naming.directory.SearchResult> ne)
This adds a
NamingEnumeration of SearchResult to
this LdapResult. |
void |
addEntry(LdapEntry e)
This adds a new entry to this
LdapResult. |
void |
addEntry(javax.naming.directory.SearchResult sr)
This adds a new entry to this
LdapResult. |
void |
clear()
This removes all entries from this
LdapResult. |
java.util.Collection<LdapEntry> |
getEntries()
This returns a
Collection of LdapEntry for this
LdapResult. |
LdapEntry |
getEntry(java.lang.String dn)
This returns the
LdapEntry for this LdapResult
with the supplied DN. |
int |
hashCode()
This returns the hash code for this object.
|
int |
size()
This returns the number of entries in this result.
|
java.util.List<javax.naming.directory.SearchResult> |
toSearchResults()
This returns a
List of SearchResult that
represent the entries in this LdapResult. |
java.lang.String |
toString()
This returns a string representation of this object.
|
equalsprotected static final int HASH_CODE_SEED
public AbstractLdapResult(LdapBeanFactory lbf)
AbstractLdapResult with the supplied ldap bean
factory.lbf - LdapBeanFactorypublic java.util.Collection<LdapEntry> getEntries()
Collection of LdapEntry for this
LdapResult.getEntries in interface LdapResultCollectionpublic LdapEntry getEntry(java.lang.String dn)
LdapEntry for this LdapResult
with the supplied DN.getEntry in interface LdapResultdn - StringLdapEntrypublic void addEntry(LdapEntry e)
LdapResult.addEntry in interface LdapResulte - LdapEntrypublic void addEntry(javax.naming.directory.SearchResult sr)
throws javax.naming.NamingException
LdapResult.addEntry in interface LdapResultsr - SearchResultjavax.naming.NamingException - if the search results cannot be readpublic void addEntries(java.util.Collection<LdapEntry> c)
Collection of entries to this
LdapResult. The list should contain LdapEntry objects.addEntries in interface LdapResultc - Collectionpublic void addEntries(javax.naming.NamingEnumeration<javax.naming.directory.SearchResult> ne)
throws javax.naming.NamingException
NamingEnumeration of SearchResult to
this LdapResult.addEntries in interface LdapResultne - NamingEnumerationjavax.naming.NamingException - if the search results cannot be readpublic void addEntries(java.util.Iterator<javax.naming.directory.SearchResult> i)
throws javax.naming.NamingException
Iterator of SearchResult to this
LdapResult.addEntries in interface LdapResulti - Iteratorjavax.naming.NamingException - if the search results cannot be readpublic int size()
size in interface LdapResultintpublic void clear()
LdapResult.clear in interface LdapResultpublic int hashCode()
hashCode in class AbstractLdapBeanintpublic java.lang.String toString()
toString in class java.lang.ObjectStringpublic java.util.List<javax.naming.directory.SearchResult> toSearchResults()
List of SearchResult that
represent the entries in this LdapResult.toSearchResults in interface LdapResultListCopyright © 2014. All Rights Reserved.