}
// disable instantiation policy validation during descriptor initialization
SessionEventListener eventListener = new SessionEventListener();
eventListener.setShouldValidateInstantiationPolicy(false);
XMLPlatform platform = new SAXPlatform();
platform.getConversionManager().setLoader(loader);
XMLContext xmlContext = new XMLContext(proj, loader, eventListener);
if(generator.getAnnotationsProcessor().getPackageToNamespaceMappings().size() > 1){
((XMLLogin)xmlContext.getSession(0).getDatasourceLogin()).setEqualNamespaceResolvers(false);
}