简体   繁体   English

使用扩展点:找不到可配置的元素

[英]Using Extension Points: no configurable elements found

i created an extension point for one plugin(A). 我为一个插件(A)创建了一个扩展点。 Another plugin(B) is setup as an extension to the ep from the first plugin. 另一个插件(B)被设置为第一个插件对ep的扩展。

When trying to use the extension point eclipse in A eclipse tells me that, it is not able to find configurable elements for the this extension point. 当尝试在eclipse中使用扩展点eclipse时,告诉我,它无法为此扩展点找到可配置的元素。 The extension point itself is found. 找到扩展点本身。

I'm suspecting plugin B is not started at all. 我怀疑插件B根本没有启动。 How can i check this? 我该如何检查?

Here is the code, where the extension point gets called: 这是代码,扩展点被调用:

IExtensionRegistry extensionRegistry = Platform.getExtensionRegistry();
        IExtensionPoint[] extensionPoints = extensionRegistry.getExtensionPoints("A.extensionpoints");
        //Prints both defined EP's
        for (IExtensionPoint iExtensionPoint : extensionPoints) {
            System.err.println(iExtensionPoint.getUniqueIdentifier());
            System.err.println(iExtensionPoint.getExtensions().length); 
        }
        IExtensionPoint extensionPoint = extensionRegistry.getExtensionPoint("A.extensionpoints.HavingProblemsWith");
        System.err.println(extensionPoint.getLabel());//Prints the Label
        System.err.println(extensionPoint.getConfigurationElements().length);// => 0

Fire up eclipse with the -console option. 使用-console选项启动eclipse。 Then you have tools to view the status of the plugins and to start them, if you want so. 然后,您可以根据需要使用工具查看插件状态并启动它们。 It may give you some ideas on why the plugin hasn't been started. 它可能会为您提供一些有关为何尚未启动插件的想法。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM