Alternative XSLT processor to Apache Xalan - xslt

I am currently using the Apache Xalan XSLT processor in my Java application, but I would like to use some alternative solution which supports use of extension functions. Xalan seems to be out of date and buggy. I know of Saxonixa Saxon, but it is closed sourced. Is there some open source and well working alternative?

The current open source version of Saxon, Saxon-HE 9.9, supports "integrated extension functions" (functions written to a particular Saxon-defined Java interface). It doesn't support "reflexive" extension functions (calls to arbitrary Java classes/methods found on the classpath).
Note that if you move to Saxon, with support for XSLT 2.0 and 3.0, you will find there is much less need for calling out to Java, because (a) the built-in function library is much larger, and (b) you can implement your own functions using the xsl:function declaration.

Related

Does Libxslt support mutable arguments?

In our company, we are moving from MSXML 6.0 engine to Libxslt.
Our XSLT code contains a lot of flags, counters and arrays implemented in JS, which MSXML supported and Libxslt does not.
As a replacement, I am looking for some sort of mutable arguments support. Does Libxslt have one? Something along the line of saxon:assignable functionality
I know that that is against the "natural" language design, but I am dealing with a large body of flawed code that would be very difficult to re-write...

C++ implementation of XML schema XSD 1.1?

Is there any existing C++ implementation of the XML Schema XSD 1.1?
I found xerces-c++-3.1.1, but it only implements XSD 1.0.
The java counterpart of this project does implement XSD 1.1.
I am notably looking for a way to implement the 'assert' functionality.
The only released XSD 1.1 processors I am aware of are Xerces-J and Saxon-EE, which are both Java-based (though Saxon-EE is also released on .NET).
(EDIT, SIX YEARS LATER)
There is also an implementation from Altova.

How to transform XML and XSLT using Visual C++ 6

I have to admit that I'm still using Visual C++ 6 and don't plan to upgrade any time soon due to the complexity of the project I'm working on.
Can anyone provide me an example to transform XML data with XSLT stylesheet using Visual C++ 6 in unmanaged code? If this old workhorse doesn't have that feature, which component is considered to be the best in the market?
From Windows apps one XSLT processor to use is the COM object as part of the MSXML SDK. (I have used early versions of this with VS6 but as it is COM I can't see why this will not work with the latest version)
You can also use pure C/C++ libraries such as Xalan or Aribica
You could have a look at the answers to this SO question: 'Is there any C++ XSLT library?'.
Apache Xalan looks to be appropriate, though I have no personal experience with this lib.
Another option is to run the XSLT processor (executable) directly from your program via system() call or similar mechanism.
If you really need a COM component to achieve what you want, you might consider to wrap one of these solutions in your own COM component implementation.

Running XQuery transformation from XSLT

I have some XQuery files, which are generally crafted for syntax checking of atomic types xs:ID and xs:IDREF.
Is there any pure XSLT way (except any third party like zorba! or marklogic or without using java custom extension functions.
So far I've thought to write extension functions(using «xsl:function»). If anyone have any other idea? Suggestions are welcome.
If you want to mix XSLT and XQuery then I think you need a product allowing that with the help of extension functions, like Saxon does with http://www.saxonica.com/documentation/extensions/functions/query.xml.

VC++ project: MSXML vs any other XML libraries

We are aware of MSXML, based on COM technologies. We want to use it for a VC++ project starting soon. Are there any other XML libraries do good compared to MSXML?
TinyXML - A C++ open source library
Will you be using the .Net Framework if so you may want to look at using linq to xml.
Take a look at RapidXML. Also, Boost.PropertyTree is an abstraction over property trees (XML, JSON, INI, INFO at the time of writing) and relies on RapidXML for its XML parser.
We ditched MSXML in favor of Xerces for our project, although Xerces is also a big, complicated beast. The TinyXML suggestion is probably a good one if it does everything you need it to. If you only need basic SAX model support (and not a DOM), then you might also consider expat which is one of the first widely used XML parsers.
LIBXML
"Libxml2 is the XML C parser and toolkit developed for the Gnome project (but usable outside of the Gnome platform), it is free software available under the MIT License."
I have used it for many years on Win32 projects without problem. It supports both SAX and DOM style reading.
You must take a look at Microsoft XmlLite which is a pull parser for pure C++. The primary goals of XmlLite are ease of use, performance, and standards compliance.