Update framework from site on eclipse oxygen
Post here questions and problems related to oXygen frameworks/document types.
-
- Posts: 12
- Joined: Tue Oct 04, 2016 12:18 pm
Update framework from site on eclipse oxygen
Hi,
We have an eclipse RCP IDE with oxygen plugin installed and we also have an update site for the IDE plugins. Now we need to be able to update a custom framework from site.
Is it possible to update custom oxygen frameworks from the same update site (extending)? or we need an oxygen update site? if so will that work on a eclipse oxygen plugin? Please advice on the best way to do that.
We are using oxygen author 17
Many thanks,
Oscar
We have an eclipse RCP IDE with oxygen plugin installed and we also have an update site for the IDE plugins. Now we need to be able to update a custom framework from site.
Is it possible to update custom oxygen frameworks from the same update site (extending)? or we need an oxygen update site? if so will that work on a eclipse oxygen plugin? Please advice on the best way to do that.
We are using oxygen author 17
Many thanks,
Oscar
-
- Posts: 1017
- Joined: Wed Nov 16, 2005 11:11 am
Re: Update framework from site on eclipse oxygen
Post by alex_jitianu »
Hi Oscar,
You probably already have your own Eclipse plugin that uses the extension points provided by our oXygen XML Eclipse plug-in. if that's the case, then your plugin can set an additional frameworks location using our API:
A good place to call this would be an IStartup Eclipse extension because that gets called very early (in v17 this API needs to be called before Oxygen loads the frameworks). In Oxygen version 18.0 you can call this API anytime and we will reload the frameworks automatically. In version 18 there is also an EclipseWorkspaceAccessPluginExtension extension which is a good place to call this API.
So whenever your plugin gets updated it will also receive the latest Oxygen frameworks and, on startup, it will make Oxygen use them using our API. Please let me know if this solution applies in your case.
Best regards,
Alex
You probably already have your own Eclipse plugin that uses the extension points provided by our oXygen XML Eclipse plug-in. if that's the case, then your plugin can set an additional frameworks location using our API:
Code: Select all
PluginWorkspaceProvider.getPluginWorkspace().setGlobalObjectProperty(
"additional.frameworks.directories",
new String[] {"absolute.file.path.to.frameworks.dir"});
So whenever your plugin gets updated it will also receive the latest Oxygen frameworks and, on startup, it will make Oxygen use them using our API. Please let me know if this solution applies in your case.
Best regards,
Alex
-
- Posts: 12
- Joined: Tue Oct 04, 2016 12:18 pm
Re: Update framework from site on eclipse oxygen
Hi Alex,
Thank you for your answer.
We can certainly use the additional framework locations feature, however if my updated plugin comes as a dependency (jar file) from the update site server, how can I point oxygen framework locations to that plugin?
Ideally we would like to extend the frameworks in a similar way as we extend document types, by extensions. Possible?
Please advice,
Thanks,
Oscar
Thank you for your answer.
We can certainly use the additional framework locations feature, however if my updated plugin comes as a dependency (jar file) from the update site server, how can I point oxygen framework locations to that plugin?
Ideally we would like to extend the frameworks in a similar way as we extend document types, by extensions. Possible?
Please advice,
Thanks,
Oscar
-
- Posts: 1017
- Joined: Wed Nov 16, 2005 11:11 am
Re: Update framework from site on eclipse oxygen
Post by alex_jitianu »
Hi Oscar,
What your plugin must to is set D:\eclipse\plugins\com.myplugin.editor_17.1.0.v2015111718\frameworks as an additional frameworks location. Once it does that Oxygen will automatically load the document types from that location. When your plugin gets updates it will bring new versions for the frameworks too and, again, they will be loaded automatically.
So the question that remains to be answered is how does your plugin set the previous mentioned directory as an additional frameworks location? Well, your plugin could implement the IStartup extension point. On the earlyStartup() you can use our API like this:
Please let me know is there are still unclear aspects.
Best regards,
Alex
Well, both a framework and a document type refer to the same thing. We kind of use both terms to refer to the configuration associated with a specific XML vocabulary.Ideally we would like to extend the frameworks in a similar way as we extend document types, by extensions. Possible?
What I'm thinking is that your plugin has these document type extensions bundle in it. For example:how can I point oxygen framework locations to that plugin?
Code: Select all
D:\eclipse\plugins\com.myplugin.editor_17.1.0.v2015111718\frameworks\my_framework_directory
So the question that remains to be answered is how does your plugin set the previous mentioned directory as an additional frameworks location? Well, your plugin could implement the IStartup extension point. On the earlyStartup() you can use our API like this:
Code: Select all
Bundle bundle = Platform.getBundle("my_plugin_id");
Path path = new Path("frameworks");
URL eclipseSpecificURL = FileLocator.find(bundle, path, null);
try {
URL genericURL = FileLocator.resolve(eclipseSpecificURL);
String absolutePath = new File(genericURL.getPath()).getAbsolutePath();
// Oxygen API
PluginWorkspaceProvider.getPluginWorkspace().setGlobalObjectProperty(
"additional.frameworks.directories",
new String[] {absolutePath});
} catch (IOException e) {
e.printStackTrace();
}
Best regards,
Alex
Return to “SDK-API, Frameworks - Document Types”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service