Registry.getServer(classname);
contentHandlerServer.setListener(requestListener);
// Set the name of the content handler by updating the
// ApplicationDescriptor
final DefaultContentHandlerRegistry defaultRegistry =
DefaultContentHandlerRegistry
.getDefaultContentHandlerRegistry(registry);
final ApplicationDescriptor currentDescriptor =
ApplicationDescriptor.currentApplicationDescriptor();
handlerName =
handlerName != null ? handlerName : currentDescriptor.getName();
final ApplicationDescriptor descriptor =
new ApplicationDescriptor(currentDescriptor, handlerName, null);
defaultRegistry.setApplicationDescriptor(descriptor, id);
}