Page 1 of 1

testing xalan transforms with internal lookups

Posted: Wed May 08, 2013 1:53 am
by rberge
We have java code that does some lookups within the stylesheet transformations, which is something allowed by xalan.
It looks rather like this:
xmlns:xalan="http://xml.apache.org/xalan"
xmlns:lookupHandler="HandlerLookup"
extension-element-prefixes="lookupHandler">

<xalan:component prefix="lookupHandler" functions="performLookup">
<xalan:script lang="javaclass" src="xalan://com.ge.hcit.xje.lookup.LookupHandlerFactory" />
</xalan:component>

I don't have the java code on my computer where I am running Oxygen. I have tried to set up to run it remotely from the server where it exists but haven't been able to get that to work. Should I be able to do this and can you give instructions on exactly where in Oxygen to set it up. Otherwise, i have to spend a bunch of time redoing the transformations to do the lookups from a local file.

Re: testing xalan transforms with internal lookups

Posted: Wed May 08, 2013 4:46 pm
by adrian
Hello,

If you want to set this up in Oxygen, you will need the compiled Java classes (or jar libraries) with the LookupHandlerFactory implementation. When configuring the transformation scenario (Document -> Transformation -> "Configure Transformation Scenario(s)", Edit), press the Extensions button (below the Transformer combo) and you can add the classes folder and/or the jar libraries there. The jars could be even located remotely (HTTP/WebDAV), but they will be run locally.

Regards,
Adrian