Home » Eclipse Projects » Plugin Development Environment (PDE) » When is a plugin Editable?
When is a plugin Editable? [message #47101] |
Mon, 16 February 2009 12:30  |
Eclipse User |
|
|
|
I am using the PDE API, and want to add Extensions to a plugin, but all my
plugins return false to isEditable().
The basic code I am using is:
IPluginModelBase[] allModels = PluginRegistry.getActiveModels();
allContributers = Arrays.asList(allModels);
writeableContributers = new ArrayList<IPluginModelBase>();
for (IPluginModelBase model : getAllContributers()){
if (model.isEditable()){
writeableContributers.add(model);
}
}
In this case my "writeable" collection is always empty.
I have the source of (some of) the plugins in my workspace, and I can edit
them using the PDE itself, so I'm a bit unlcear as to what I need to do to
make them editable.
Thanks in advance,
Richard
|
|
| |
Re: When is a plugin Editable? [message #47269 is a reply to message #47131] |
Tue, 17 February 2009 05:01  |
Eclipse User |
|
|
|
Hi Chris,
So the context is:
What we have at the moment are a number of different Extension Points that
often impact on each other. Also our users have built a hierarchy of
contributions to these extension points, so we are writing a little "SDK"
to present them in a way that makes sense to users of the tool.
In this specific example (I'm starting simple), users can add menu/toolbar
actions to do slightly different things to the built in tools. When they
do this, they will probably want to disable the builtins (or even
contributions that some one else made further down their plugin hierarchy).
The way to disable is through a different extension point.
So... the "SDK" shows the all things they have contributed from any of
their plugin along side the built-ins, and I want to be able to
right-click and create a "disable" contribution based on the selection in
that table.
The intent is NOT that the contribution is made immediately to the current
workspace, I just want to add it to a plugin that is being "edited"
locally for subsequent deployment.
Hope that makes sense.
Richard
PS I don't think the JavaDoc I read really suggests this is not possible..
Chris Aniszczyk wrote:
> Richard Craddock wrote:
>> I am using the PDE API, and want to add Extensions to a plugin, but all
>> my plugins return false to isEditable().
>>
>> In this case my "writeable" collection is always empty.
>>
>> I have the source of (some of) the plugins in my workspace, and I can
>> edit them using the PDE itself, so I'm a bit unlcear as to what I need
>> to do to make them editable.
> It's currently not possible, read the Javadoc of IPluginModelBase.
> There's plenty of bugs open around this API issue:
> 190324: [API] Open API for programmatically adding extensions
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=190324
> 216037: [API] Way to modify MANIFEST files
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=216037
> 190324: [API] Open API for programmatically adding extensions
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=190324
> There are ways to do this using not API, but before I say anything, what
> are you trying to do :)?
> Cheers,
> Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
> http://twitter.com/caniszczyk | http://twitter.com/eclipsesource
|
|
| |
Re: When is a plugin Editable? [message #592075 is a reply to message #47131] |
Tue, 17 February 2009 05:01  |
Eclipse User |
|
|
|
Hi Chris,
So the context is:
What we have at the moment are a number of different Extension Points that
often impact on each other. Also our users have built a hierarchy of
contributions to these extension points, so we are writing a little "SDK"
to present them in a way that makes sense to users of the tool.
In this specific example (I'm starting simple), users can add menu/toolbar
actions to do slightly different things to the built in tools. When they
do this, they will probably want to disable the builtins (or even
contributions that some one else made further down their plugin hierarchy).
The way to disable is through a different extension point.
So... the "SDK" shows the all things they have contributed from any of
their plugin along side the built-ins, and I want to be able to
right-click and create a "disable" contribution based on the selection in
that table.
The intent is NOT that the contribution is made immediately to the current
workspace, I just want to add it to a plugin that is being "edited"
locally for subsequent deployment.
Hope that makes sense.
Richard
PS I don't think the JavaDoc I read really suggests this is not possible..
Chris Aniszczyk wrote:
> Richard Craddock wrote:
>> I am using the PDE API, and want to add Extensions to a plugin, but all
>> my plugins return false to isEditable().
>>
>> In this case my "writeable" collection is always empty.
>>
>> I have the source of (some of) the plugins in my workspace, and I can
>> edit them using the PDE itself, so I'm a bit unlcear as to what I need
>> to do to make them editable.
> It's currently not possible, read the Javadoc of IPluginModelBase.
> There's plenty of bugs open around this API issue:
> 190324: [API] Open API for programmatically adding extensions
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=190324
> 216037: [API] Way to modify MANIFEST files
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=216037
> 190324: [API] Open API for programmatically adding extensions
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=190324
> There are ways to do this using not API, but before I say anything, what
> are you trying to do :)?
> Cheers,
> Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
> http://twitter.com/caniszczyk | http://twitter.com/eclipsesource
|
|
|
Goto Forum:
Current Time: Wed May 07 16:45:13 EDT 2025
Powered by FUDForum. Page generated in 0.04996 seconds
|