adapters extension point [message #530896] |
Sun, 02 May 2010 13:28 |
Madhu Samuel Messages: 199 Registered: July 2009 |
Senior Member |
|
|
Folks,
I created an rcp with just 2 views. A table viewer and a properties view.
I used the adapters extension point as follows.
<extension
id="mycompany.adapterfactory.one"
point="org.eclipse.core.runtime.adapters">
<factory
adaptableType="com.mycompany.employee.model.Employee"
class=" com.mycompany.propertiesview.adapters.EmployeePropertiesAdap terFactory ">
<adapter
type="org.eclipse.ui.views.properties.IPropertySource">
</adapter>
</factory>
</extension>
But I think that the adapter factory is not getting registered. The properties view is not getting updated. When the AdapterManager looks for Adapter factories for IPropertySource, it returns null.
Is there any bug related with this extension point?
Regards,
Madhu
http://eclipsebible.com
|
|
|
Re: adapters extension point [message #532368 is a reply to message #530896] |
Sun, 09 May 2010 04:09 |
|
I think I've had the same problem in that my declared AdapterFactories
are not found unless the plugin is explicitly started, in my case by
using a "startup" extension (that does nothing in #earlyStartup). Now all
of our plugins that contain AdapterFactory declarations have "startup"
extensions but this just seems wrong to me. Is there a better way? Maybe
we shouldn't be using PlatformUI.getAdapterManager().loadAdapter(Object,
String)?
I thought the extension registry parsed all extensions on application
start. If so shouldn't they have knowledge of declared factories and the
adapter types they can produce? And be able to instantiate those
factories and start their containing bundles when requested?
Puzzled,
Craig Foote
On Sun, 02 May 2010 18:58:29 +0530, Madhu Samuel wrote:
> Folks,
>
> I created an rcp with just 2 views. A table viewer and a properties
> view.
>
> I used the adapters extension point as follows.
>
> <extension
> id="mycompany.adapterfactory.one"
> point="org.eclipse.core.runtime.adapters"> <factory
> adaptableType="com.mycompany.employee.model.Employee" class="
> com.mycompany.propertiesview.adapters.EmployeePropertiesAdap terFactory
> "> <adapter
> type="org.eclipse.ui.views.properties.IPropertySource"> </adapter>
> </factory>
> </extension>
>
> But I think that the adapter factory is not getting registered. The
> properties view is not getting updated. When the AdapterManager looks
> for Adapter factories for IPropertySource, it returns null.
>
> Is there any bug related with this extension point?
|
|
|
Powered by
FUDForum. Page generated in 0.02995 seconds