/** {@inheritDoc} */ @Override public HandlerResult<SearchEntry> handle( final Connection conn, final SearchRequest request, final SearchEntry entry) throws LdapException { // Recursively searches a list of attributes and merges those results with // the existing entry. final List<String> searchedDns = new ArrayList<String>(); if (entry.getAttribute(searchAttribute) != null) { searchedDns.add(entry.getDn()); readSearchAttribute(conn, entry, searchedDns); } else { recursiveSearch(conn, entry.getDn(), entry, searchedDns); } return new HandlerResult<SearchEntry>(entry); }
/** * Handle the dn of a search entry. * * @param conn the search was performed on * @param request used to find the search entry * @param entry search entry to extract the dn from * @return handled dn */ protected String handleDn( final Connection conn, final SearchRequest request, final SearchEntry entry) { return entry.getDn(); }