Skip to content

Commit ca1b1c3

Browse files
OSGi Service as Global EPackageRegistry
The default EPackage Registry can be overwritten in mutlple ways (System property or ExtensionPoint). With this, if non of the other mechanisms apply, there now can be a service that acts as the static Registry. Signed-off-by: Juergen Albert <[email protected]>
1 parent 8c230d4 commit ca1b1c3

File tree

7 files changed

+718
-7
lines changed

7 files changed

+718
-7
lines changed

plugins/org.eclipse.emf.common/src/org/eclipse/emf/common/EMFPlugin.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,9 @@ public abstract class EMFPlugin extends DelegatingResourceLocator implements Res
8282
boolean result = false;
8383
try
8484
{
85+
// With this we make sure, that we are really in a proper Eclipse Environment with everything we need.
86+
// Some supplements pretend that the Platform is running, but don't provide a ExtensionRegistry.
87+
FrameworkUtil.getBundle(EMFPlugin.class).loadClass("org.eclipse.core.runtime.IRegistryChangeListener");
8588
result = Platform.isRunning();
8689
}
8790
catch (Throwable exception)

plugins/org.eclipse.emf.ecore/META-INF/MANIFEST.MF

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
22
Bundle-ManifestVersion: 2
33
Bundle-Name: %pluginName
44
Bundle-SymbolicName: org.eclipse.emf.ecore;singleton:=true
5-
Bundle-Version: 2.38.0.qualifier
5+
Bundle-Version: 2.39.0.qualifier
66
Bundle-ClassPath: .
77
Bundle-Activator: org.eclipse.emf.ecore.plugin.EcorePlugin$Implementation$Activator
88
Bundle-Vendor: %providerName

plugins/org.eclipse.emf.ecore/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
<groupId>org.eclipse.emf</groupId>
1414
<artifactId>org.eclipse.emf.ecore</artifactId>
15-
<version>2.38.0-SNAPSHOT</version>
15+
<version>2.39.0-SNAPSHOT</version>
1616
<packaging>eclipse-plugin</packaging>
1717

1818
</project>

0 commit comments

Comments
 (0)