Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Embedding Equinox

(Redirected from Embedding)

Equinox supposed the standard SPI mechanism to embed the framework in a larger application. You put the framework jar in your classpath, and proceed as follows:


      // Obtain a framework factory.
       ServiceLoader<FrameworkFactory> loader = ServiceLoader.load(FrameworkFactory.class);
       FrameworkFactory factory = loader.iterator().next();
       // And get a framework.
       framework = factory.newFramework(configProps);
       try {
           framework.init();
       } catch (BundleException e) {
           throw new SomeRuntimeException("Failed to initialize framework", e);
       }

Back to the top