Subject: Re: [xsl] Convert JSON to XML? From: "Dave Pawson dave.pawson@xxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Fri, 2 May 2025 16:39:21 -0000 |
Anyone remember James @id generation? Might be useful for valid element names. regards On Fri, 2 May 2025 at 17:34, Wendell Piez wapiez@xxxxxxxxxxxxxxx < xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote: > Dan, > > Given that you need something unencumbered by IP restrictions that you > know how to use and adapt, I would bet the easy way forward would be to add > logical layers of your own (using XSLT) to the basic format provided for by > the generic tool. You might be surprised at how rapidly you can put > together something useful enough. > > This is actually a good demo of XSLT's combination of power and > flexibility to solve a problem that seems more generic than it actually is. > (Or rather: the problem is generic. The mapping you want to implement in > your case is not.) Who needs something more tailored to this task than XSLT? > > Today, I might use XProc for this, depending. XProc can deliver the XPath > XML for free from the JSON, then drop your XSLT on it -- or I might do it > in XSLT only. > > Cheers, Wendell > > > > > On Thu, May 1, 2025 at 6:35b/PM dvint@xxxxxxxxx < > xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote: > >> I know (and have been using) the xlst json-to-xml() function for this >> purpose, but it is a pretty basic result. I happened to try the JSON to >> XML funtion in oXygen and got what I'd say is a much better result where >> I had some unique elemeent names instead of everything being a map or a >> string element. >> >> I was poking around to try and find a tool/library I could use in my >> conversion path and everything I'm finding is an online tool or has a >> price. Currently I'm developing a conversion pipeline and can leverage >> oXygen for this, but I need something I can build into a tool and load >> into a Docker image for the production implementation. >> >> Anyone have a suggestion? >> >> ..dan >> >> >> > > -- > ...Wendell Piez... ...wendell -at- nist -dot- gov... > ...wendellpiez.com... ...pellucidliterature.org... ...pausepress.org... > ...github.com/wendellpiez... ...gitlab.coko.foundation/wendell... > XSL-List info and archive <http://www.mulberrytech.com/xsl/xsl-list> > EasyUnsubscribe <http://lists.mulberrytech.com/unsub/xsl-list/2607481> (by > email <>) > -- Dave Pawson XSLT XSL-FO FAQ. Docbook FAQ.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Convert JSON to XML?, Wendell Piez wapiez@ | Thread | Re: [xsl] What is the correct xpath, ajbufort@xxxxxxxxxxx |
Re: [xsl] Convert JSON to XML?, Wendell Piez wapiez@ | Date | Re: [xsl] Convert JSON to XML?, dvint dvint@xxxxxxxx |
Month |