[oXygen-user] Support for jar: URNs?

Radu Coravu radu_coravu at sync.ro
Tue Nov 15 06:24:43 CST 2011


Hi Eliot,

If the catalog file is located directly on the local drive, relative 
references to it are interpreted as having the same protocol (which is 
the "file" protocol). I consider this to be correct.
I understand that you would like relative references like this: 
"test.zip!/catalog.xml" to be expanded to absolute URLs having the 
protocol something like "zip:file" but this is not quite easy or correct 
to accomplish and would require some patches to the Xerces catalog resolver.

What I tested and could be used as a workaround:
Have the catalog file located directly inside the zip (or jar).
For example in the catalogs list I referenced it like this:

> zip:file:/D:/projects/eXml/samples/dita/flowers/concepts/test.zip!/catalog.xml

and it contained a relative reference like this:

>  <uri
>         name="http://test/res/plugin/dita4publishers/net.sourceforge.dita4publishers.common.xslt/xsl/lib/relpath_util.xsl"
>         uri="personal.xsl"/>

which got solved also inside the same zip.

Regards,
Radu

Radu Coravu
<oXygen/>  XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com


On 11/14/2011 8:30 PM, Eliot Kimber wrote:
> I'm trying to set up an entity resolution catalog that resolves to files in
> a jar file.
>
> I can get it to work as expected if the URL to the jar is absolute, e.g.:
>
> <uri
> name="rsuite:/res/plugin/dita4publishers/net.sourceforge.dita4publishers.com
> mon.xslt/xsl/lib/relpath_util.xsl"
>
> uri="jar:file:///Users/ekimber/workspace/rsuite-dita-support-quickfix/java/l
> ib/dita4publishers-rsuite-plugin.jar!..."/>
>
> However, a relative URL (relative to the catalog), does not work.
>
> Is it possible for Oxygen to make a relative URL part of a jar: URN resolve
> relative to the catalog?
>
> This is to support development of XSLTs that import modules that, when
> deployed into the RSuite CMS, will be referenced by an RSuite-specific URN.
> The catalog allows the XSLTs to be developed without having to swap
> different URNs in and out. I'm trying to set up a system whereby developers
> can get the jar with the included modules from Ivy and then, by using an
> invariant catalog, have the inclusions work.
>
> I can't think of another way of doing it.
>
> Thanks,
>
> E.
>
>




More information about the oXygen-user mailing list