net.sf.ldaptemplate
Class LdapTemplate.ContextMapperCallbackHandler

java.lang.Object
  extended bynet.sf.ldaptemplate.CollectingSearchResultCallbackHandler
      extended bynet.sf.ldaptemplate.LdapTemplate.ContextMapperCallbackHandler
All Implemented Interfaces:
SearchResultCallbackHandler
Enclosing class:
LdapTemplate

public class LdapTemplate.ContextMapperCallbackHandler
extends CollectingSearchResultCallbackHandler

A CollectingSearchResultCallbackHandler to wrap a ContextMapper. That is, the found objects are extracted from all SearchResults, and then passed to the specified ContextMapper for translation.

Author:
Mattias Arthursson

Constructor Summary
LdapTemplate.ContextMapperCallbackHandler(ContextMapper mapper)
           
 
Method Summary
protected  java.lang.Object getObjectFromResult(javax.naming.directory.SearchResult searchResult)
          Handle a single search result and transform it to an Object.
 
Methods inherited from class net.sf.ldaptemplate.CollectingSearchResultCallbackHandler
getList, handleSearchResult
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LdapTemplate.ContextMapperCallbackHandler

public LdapTemplate.ContextMapperCallbackHandler(ContextMapper mapper)
Method Detail

getObjectFromResult

protected java.lang.Object getObjectFromResult(javax.naming.directory.SearchResult searchResult)
Description copied from class: CollectingSearchResultCallbackHandler
Handle a single search result and transform it to an Object.

Specified by:
getObjectFromResult in class CollectingSearchResultCallbackHandler
Parameters:
searchResult - a SearchResult from a search operation.
Returns:
an object constructed from the data in the SearchResult.


Copyright © 2006 Jayway AB. All Rights Reserved.