|  |  | 
 |  |  |           IllegalAccessException, IllegalArgumentException, InvocationTargetException, IOException { | 
 |  |  |     Map<String, HttpHandler> sharedHandlers = new HashMap(); | 
 |  |  |     Iterator<ContextDescriptor> contextIterator = contextList.iterator(); | 
 |  |  |     Authenticator auth = null; | 
 |  |  |     while (contextIterator.hasNext()) { | 
 |  |  |       ContextDescriptor cd = contextIterator.next(); | 
 |  |  |       HttpHandler h = buildHandler(cd, sharedHandlers); | 
 |  |  | 
 |  |  |               ctx.getAttributes().put("serverDataProviderList", sdp); | 
 |  |  |           } | 
 |  |  |         }         | 
 |  |  |         Authenticator auth = createAuthenticator(d); | 
 |  |  |         if (auth instanceof Authenticator && cd.authenticator instanceof String) { | 
 |  |  |         if(cd.authenticator instanceof String) { | 
 |  |  |           if(!(auth instanceof Authenticator)) { | 
 |  |  |             auth = createAuthenticator(d); | 
 |  |  |           } | 
 |  |  |           if(auth instanceof Authenticator) { | 
 |  |  |             ctx.setAuthenticator(auth);       | 
 |  |  |             ctx.getAttributes().putAll(d.authenticator.attributes); | 
 |  |  |             fireAuthenticatorCreated(ctx, auth); | 
 |  |  |             fireAuthenticatorCreated(ctx, auth); // event umbenennen in etwas wie authAdded oder so | 
 |  |  |         } | 
 |  |  |            | 
 |  |  |         } | 
 |  |  |          | 
 |  |  |         //Authenticator auth = createAuthenticator(d); | 
 |  |  |         //if (auth instanceof Authenticator && cd.authenticator instanceof String) { | 
 |  |  |         //    ctx.setAuthenticator(auth);       | 
 |  |  |         //    ctx.getAttributes().putAll(d.authenticator.attributes); | 
 |  |  |         //    fireAuthenticatorCreated(ctx, auth); | 
 |  |  |         //} | 
 |  |  |         fireHandlerCreated(ctx, h); | 
 |  |  |         fireContextCreated(ctx); | 
 |  |  |       } else { |