edu.vt.middleware.ldap.ldif
Class LdifSearch

java.lang.Object
  extended by edu.vt.middleware.ldap.LdapSearch
      extended by edu.vt.middleware.ldap.ldif.LdifSearch

public class LdifSearch
extends LdapSearch

LdifSearch queries an LDAP and returns the result as an LDIF. Each instance of LdifSearch maintains it's own pool of LDAP connections.

Version:
$Revision: 1330 $ $Date: 2010-05-23 18:10:53 -0400 (Sun, 23 May 2010) $
Author:
Middleware Services

Field Summary
 
Fields inherited from class edu.vt.middleware.ldap.LdapSearch
beanFactory, logger, pool
 
Constructor Summary
LdifSearch(LdapPool<Ldap> pool)
          This creates a new LdifSearch with the supplied pool.
 
Method Summary
 void search(String query, String[] attrs, Writer writer)
          This will perform an LDAP search with the supplied query and return attributes.
 
Methods inherited from class edu.vt.middleware.ldap.LdapSearch
close, finalize, getLdapBeanFactory, search, setLdapBeanFactory
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LdifSearch

public LdifSearch(LdapPool<Ldap> pool)
This creates a new LdifSearch with the supplied pool.

Parameters:
pool - LdapPool
Method Detail

search

public void search(String query,
                   String[] attrs,
                   Writer writer)
            throws NamingException,
                   IOException
This will perform an LDAP search with the supplied query and return attributes. The results will be written to the supplied Writer.

Overrides:
search in class LdapSearch
Parameters:
query - String to search for
attrs - String[] to return
writer - Writer to write to
Throws:
NamingException - if an error occurs while searching
IOException - if an error occurs while writing search results


Copyright © 2003-2010 Virginia Tech. All Rights Reserved.