protected EPackage.Registry delegateRegistry(ClassLoader classLoader) { return getRegistry(classLoader); }
protected EPackage.Registry delegateRegistry(ClassLoader classLoader) { return getRegistry(classLoader); }
/** * Returns the package registry associated with the given class loader. * @param classLoader the class loader. * @return the package registry associated with the given class loader. */ public static synchronized EPackage.Registry getRegistry(ClassLoader classLoader) { EPackage.Registry result = classLoaderToRegistryMap.get(classLoader); if (result == null) { if (classLoader != null) { result = new EPackageRegistryImpl(getRegistry(classLoader.getParent())); classLoaderToRegistryMap.put(classLoader, result); } } return result; }
/** * Returns the package registry associated with the given class loader. * @param classLoader the class loader. * @return the package registry associated with the given class loader. */ public static synchronized EPackage.Registry getRegistry(ClassLoader classLoader) { EPackage.Registry result = classLoaderToRegistryMap.get(classLoader); if (result == null) { if (classLoader != null) { result = new EPackageRegistryImpl(getRegistry(classLoader.getParent())); classLoaderToRegistryMap.put(classLoader, result); } } return result; }