EjbModuleBuilder.EarData earData = (EjbModuleBuilder.EarData) module.getRootEarContext().getGeneralData().get(EjbModuleBuilder.EarData.class);
Collection<EjbJarInfo> ejbJars = Collections.emptySet();
if (earData != null) {
ejbJars = earData.getEjbJars();
}
JndiEncInfoBuilder jndiEncInfoBuilder = new JndiEncInfoBuilder(ejbJars);
JndiEncInfo jndiEncInfo;
if (module.isStandAlone()) {
jndiEncInfo = jndiEncInfoBuilder.build(consumer, "GeronimoEnc", null);
} else {
jndiEncInfo = jndiEncInfoBuilder.build(consumer, "GeronimoEnc", module.getTargetPath());
}
JndiEncBuilder jndiEncBuilder = new JndiEncBuilder(jndiEncInfo, module.getName());
map = jndiEncBuilder.buildMap();
} catch (OpenEJBException e) {
throw new DeploymentException(e);