if (moduleLoader != null) {
if (logger.isDebugEnabled()) logger.debug("Loading module " + definition + " using ModuleLoader " + moduleLoader);
context = loadApplicationContext(application, classLoader, moduleLoader, parent, definition);
final String applicationId = application.getId();
moduleLoader.afterRefresh(applicationId, context, definition);
}
else if (delegatingLoader != null) {
if (logger.isDebugEnabled()) logger.debug("Loading module " + definition + " using DelegatingContextLoader " + moduleLoader);
context = delegatingLoader.loadApplicationContext(parent, definition);
}