[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
|
[news.eclipse.tools] Re: publishing extension points - help!
|
Hi Vlad,
"Vlad Klicnik" <klicnik@xxxxxxxxxx> wrote in message
news:3B7C36FE.1456F7F9@xxxxxxxxxxxxx
> Judah, the way you do this is by calling APIs in the
> org.eclipse.core.runtime package. In particular, the following are useful
>
> Platform.getPluginRegistry()
> IPluginRegistry.getXXX ... various calls to get descriptors for plugins,
> extension points, extensions, etc
> methods on IPluginDescriptor, IExtension, IExtensionPoint,
> IConfigurationElement
>
> So to find out which items were configured into your extension point
> "com.xyz.myplugin.foopoint" by some other plugin extensions you could do
>
> IConfigurationElement[] cfg;
> cfg =
>
Platform.getPluginRegistry().getConfigurationElementsFor("com.xyz.myplugin.f
oopoint");
>
> To actually interact with one of the extensions (eg. with the first one in
> the list returned above) you could then call
>
> IFoo someFoo = (IFoo) cfg[0].createExecutableExtension("fooclass");
>
I have some more questions if you don't mind...
What is "fooclass" in the call above (the docs say it is the name of a
property but I don't get what property they're talking about)?
And how does the createExecutableExtension method know to create an instance
of the IFoo class from the configuration element?
Thanks in advance,
ted stockwell