On 27-3-2014 18:06, Rushforth, Peter wrote:
There might be a JSON-to-XML library out there, which'd be my first choice.
Yes, that was my first instinct too. I found a generic json2xml.xsl library,
but it
performed too slowly. I figured I needed something more specific in order to
speed things up.
As it turns out, if you can use XSLT 3.0, you can use the new
fn:json-to-xml() function, which takes JSON as input and produces XML as
output. Conversely, it also has the fn:xml-to-json() function, which
takes a predefined XML format that represents JSON and returns the JSON
representation of that XML.
The XML produced, or the XML that is used as input is well-defined.
http://www.w3.org/TR/xslt-30/#schema-for-json.
(note: we have not yet implemented that function, otherwise I would
invite you to the testing team to have a look. If you are interested, I
can drop you a line once we have it)
Cheers,
Abel Braaksma
Exselt XSLT 3.0 processor
http://exselt.net
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--