导出产品(在 Eclipse e4 之上)并尝试启动相同的产品会留下一个错误,指出无法解决捆绑包

Exporting a product (on top of Eclipse e4) and trying to launch the same leaves behind a error stating that come Bundles could not be resolved

我创建了一个包含单个插件的示例 e4 项目,该插件由 plugin.xml 文件、fragment.e4xmi 文件、.product 文件和单个 .Java 处理程序 class 组成,它将负责在单击我的自定义菜单后立即显示消息对话框。

通过此设置,我能够在调试模式下启动产品(并且我能够看到我的自定义菜单),而我无法启动导出的产品。当我尝试这样做时出现以下错误:

java.lang.RuntimeException: Application "org.eclipse.e4.ui.workbench.swt.E4Application" could not be found in the registry. The applications available are: org.eclipse.ant.core.antRunner, org.eclipse.equinox.app.error.
at org.eclipse.equinox.internal.app.EclipseAppContainer.startDefaultApp(EclipseAppContainer.java:248)
at org.eclipse.equinox.internal.app.MainApplicationLauncher.run(MainApplicationLauncher.java:29)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603)
at org.eclipse.equinox.launcher.Main.run(Main.java:1465)

有什么方法可以解决这些问题???

如果您使用的是基于插件的构建,您的 .product 文件的依赖项页面必须列出所需的每个插件。该页面上的 'Add Required' 按钮可能会有所帮助。

对于基于功能的构建,依赖项页面必须列出包含所有必需插件的功能。