Ecplipse XML refresh dependencies programmatically

109 views Asked by At

The eclipse XML editor plugin has a button to "Reload dependencies". I am writing a Eclipse RCP and I would like to force this procedure to be called in certain cases.

Does anyone knows how to trigger it?

I found a possibly related class:

org.eclipse.wst.xml.ui.internal.handlers.ReloadDependenciesHandler.class

I am not sure to be in the good direction...

1

There are 1 answers

0
flafoux On

Looks good to me... You can try adding the handler ... in your plugin.xml:

<handler class="org.eclipse.wst.xml.ui.internal.handlers.ReloadDependenciesHandler"
             commandId="your.command.for.reload.id">
</handler>

to attach it your action bar / menu in your contribution :

<command
             commandId="your.command.for.reload.id"
             icon="path/to/icon.gif"
             style="push">
 </command>

Don' forget to add org.eclipse.wst.xml.ui as dependencies