| [news.eclipse.newcomer] Re: Accessing fragment from host plugin |
|
Tony, I'm not sure the answer. You might have better luck on the RCP newsgroup because I see lots of detailed questions there about OSGi and all this kind of plugin and fragment stuff: news://news.eclipse.org/eclipse.platform.rcpPerhaps it's not even possible to do what you are doing. E.g., I have to wonder how the host plugin can properly have a direct development time compile dependency on something that is only optionally available at runtime. I would think that normally what you're trying to do would be accomplished by the host plugin defining an extension point and having some other plugin(s) contributing to that extension point. That certainly seems like an easier and perhaps better way. I've only seen fragments used to provide things like optional translations (though I'm not saying that's their only use). Tony wrote: I'm sure I'm missing something obvious here, but I just can't figure out what it is. I'm trying to use a plugin fragment to provide optional functionality, which is one of the envisioned uses of plugin fragments according to everything I've read about them. I have a package in my host plugin, and have the same package in my fragment. I have defined an abstract class in my host plugin, and defined a concrete subclass in my fragment. The subclass in the fragment resolves it's superclass just fine, without having to import or qualify the name or anything, since both the superclass and the subclass are in the same package. |