summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2008-04-28 03:59:59 (EDT)
committerEike Stepper2008-04-28 03:59:59 (EDT)
commit161729e3dfb362901a2915b9575a52dfeab09d6a (patch)
treefa7884da4f0cbffd193af420a00d70a7dc1204a1
parent528983f0e7f1d228431b7826c56c7f41e2bf9bd2 (diff)
downloadcdo-161729e3dfb362901a2915b9575a52dfeab09d6a.zip
cdo-161729e3dfb362901a2915b9575a52dfeab09d6a.tar.gz
cdo-161729e3dfb362901a2915b9575a52dfeab09d6a.tar.bz2
[227995] Implement a self-populating EPackageRegistry
https://bugs.eclipse.org/bugs/show_bug.cgi?id=227995
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CDOPackageTypeRegistryImpl.java12
1 files changed, 4 insertions, 8 deletions
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CDOPackageTypeRegistryImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CDOPackageTypeRegistryImpl.java
index 2efc8dd..58fb786 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CDOPackageTypeRegistryImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CDOPackageTypeRegistryImpl.java
@@ -26,7 +26,6 @@ import org.eclipse.emf.ecore.plugin.EcorePlugin;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtension;
import org.eclipse.core.runtime.IExtensionPoint;
-import org.eclipse.core.runtime.IExtensionRegistry;
import org.eclipse.core.runtime.Platform;
import org.eclipse.core.runtime.dynamichelpers.ExtensionTracker;
import org.eclipse.core.runtime.dynamichelpers.IExtensionChangeHandler;
@@ -47,11 +46,6 @@ public final class CDOPackageTypeRegistryImpl extends HashMapRegistry<String, CD
{
public static final CDOPackageTypeRegistryImpl INSTANCE = new CDOPackageTypeRegistryImpl();
- private static final IExtensionRegistry EXT_REGISTRY = Platform.getExtensionRegistry();
-
- private static final String EXT_POINT = EcorePlugin.getPlugin().getBundle().getSymbolicName() + "."
- + EcorePlugin.GENERATED_PACKAGE_PPID;
-
private Object extensionTracker;
private CDOPackageTypeRegistryImpl()
@@ -96,7 +90,8 @@ public final class CDOPackageTypeRegistryImpl extends HashMapRegistry<String, CD
private void initPackageTypes()
{
- IConfigurationElement[] elements = EXT_REGISTRY.getConfigurationElementsFor(EXT_POINT);
+ IConfigurationElement[] elements = Platform.getExtensionRegistry().getConfigurationElementsFor(
+ EcorePlugin.getPlugin().getBundle().getSymbolicName(), EcorePlugin.GENERATED_PACKAGE_PPID);
addPackageTypes(elements);
}
@@ -165,7 +160,8 @@ public final class CDOPackageTypeRegistryImpl extends HashMapRegistry<String, CD
private IFilter createExtensionPointFilter()
{
- final IExtensionPoint xpt = EXT_REGISTRY.getExtensionPoint(EXT_POINT);
+ final IExtensionPoint xpt = Platform.getExtensionRegistry().getExtensionPoint(
+ EcorePlugin.getPlugin().getBundle().getSymbolicName(), EcorePlugin.GENERATED_PACKAGE_PPID);
return new IFilter()
{
public boolean matches(IExtensionPoint target)