Using Saxon CollectionFinder from Oxygen XML

Here should go questions about transforming XML with XSLT and FOP.
oyvindlg
Posts: 5
Joined: Wed Oct 02, 2013 11:05 am

Using Saxon CollectionFinder from Oxygen XML

Post by oyvindlg »

Hello,

I'm successfully running transformations using a CollectionFinder, using
ant and command line with the flag
--collection-finder-class:no.uib.saxon.ef.XlsxCollectionFinder.

When I try to run the same transformation frorth adding for the transform options in om Oxygen XML with a config
file containing

Code: Select all

<configuration xmlns="http://saxon.sf.net/ns/configuration";
    edition="EE">
    <global collectionFinder="no.uib.saxon.ef.XlsxCollectionFinder"

    />
</configuration>
I get "Content not allowed in prolog" and no error message from the
configuration.
I know the config file is used (and the class in the classpath), because I
get a warning (that the class Doesn't implement collectionUriResolver) if I
add/use the same class in the collectionUriResolver attribute in the global
element.

The Saxon version is SaxonEE 9.8.0.12 (Oxygen 21.1).

Suggestion:
I like the

Code: Select all

saxon.custom.options
property in the xspec ant build , would something similar be useful for adding ad-hoc options in Oxygen on xml-transforms for scenarios and debugging?

Best regards,
Øyvind Gjesdal
tavy
Posts: 365
Joined: Thu Jul 01, 2004 12:29 pm

Re: Using Saxon CollectionFinder from Oxygen XML

Post by tavy »

Hello,

You can also set in Oxygen the "saxon.custom.options" property. For this you need to edit the "Run XSpec Test" transformation scenario, select the "Parameters" tab, then edit the "saxon.custom.options" property and set the value to "-init:no.uib.saxon.ef.SimmetricsInitializer --collection-finder-class:no.uib.saxon.ef.XlsxCollectionFinder".
You need also to add the library containing the "no.uib.saxon.ef.XlsxCollectionFinder" class in the scenario. For this need to go in the scenario Options tab, click on the "Libraries" button, and add the library.

Yes, If I use the Saxon configuration file the transformation does not work. But this does not work also if I use Saxon from command line and I specify the given configuration using "-config" option. Probably it is a problem in Saxon or in the configuration file. I will reply to your email from the Saxon mailing list with this issue.

Best Regards,
Octavian
Octavian Nadolu
<oXygen/> XML Editor
http://www.oxygenxml.com
oyvindlg
Posts: 5
Joined: Wed Oct 02, 2013 11:05 am

Re: Using Saxon CollectionFinder from Oxygen XML

Post by oyvindlg »

Hi Octavian,

Thank you for the detailed explanation and following up on the Saxon configuration file. I did not think of testing the config file from command line, since I thought I needed PE or EE edition, but I see that the facility was made available already in Saxon 9.4. :)

Best regards
Øyvind
nkutsche
Posts: 8
Joined: Wed Feb 25, 2015 5:10 pm

Re: Using Saxon CollectionFinder from Oxygen XML

Post by nkutsche »

Hi,

FYI: I created an issue on the Saxon issue tracker for this: https://saxonica.plan.io/issues/4784

Michael committed that the collectionFinder attribute is ignored completely from the Saxon.

(I have a similar problem, but I'm calling Saxon not directly but using the calabash for an XProc pipeline)

BR, Nico
Post Reply