Dita transformation with custom protocol

Post here questions and problems related to oXygen frameworks/document types.
miquik
Posts: 7
Joined: Tue Jun 23, 2015 1:21 pm

Dita transformation with custom protocol

Post by miquik »

Hi everybody,
I have created my custom protocol handler which resolve topics agaist a database. Everythings is working well.
Now it's time to produce a PDF with Dita-Ot. How should I tell DITA's ant to use my custom protocol resolver? It is possible ti do that?

Thank you for your help!
Michele
Radu
Posts: 9057
Joined: Fri Jul 09, 2004 5:18 pm

Re: Dita transformation with custom protocol

Post by Radu »

Hi Michele,

If you want to publish from Oxygen, if the main DITA Map is opened in Oxygen you can edit the transformation scenario used for publishing and set the parameter fix.external.refs.com.oxygenxml to true. This should tell Oxygen to use the custom protocol plugin you installed in some kind of pre-processing step to retrieve DITA content for each of those references.
If you need additional Java libraries for the conversion, in the same transformation scenario in the Advanced tab there is a Libraries button which you can press to add additional JAR libraries to the publishing tool.

If you want to do the publishing directly from the command line I'm not sure if I can help you. DITA Open Toolkit 2.x added some kind of pre-processing extension which would allow you to convert other content to DITA. This is how this DITA OT plugin which dynamically converts markdown topics to DITA works:

https://github.com/jelovirt/dita-ot-markdown

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
miquik
Posts: 7
Joined: Tue Jun 23, 2015 1:21 pm

Re: Dita transformation with custom protocol

Post by miquik »

Hi Radu,
Thanks for your answer, unfortunately fix.external.refs.com.oxygenxml is already set to true but it doesn't work.
I have <topicref href="mysql:prova.dita">; when build it says "File: c:\my_folder\mysql:prova.dita" does not exist or cannot be loaded.

Don't know if this is a "resolver" problem or maybe a mysql connection problem.

Thank You,
Michele
Radu
Posts: 9057
Joined: Fri Jul 09, 2004 5:18 pm

Re: Dita transformation with custom protocol

Post by Radu »

Hi Michelle,

I'm not sure about your entire setup.
If mysql is your custom protocol maybe the referenced URL should look like mysql://prova.dita.
Or is it mapped through an XML catalog to another URL?

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply