Re: XSLT 4: map serialization

"Dimitre Novatchev [email protected]" <[email protected]> Wed, 25 Nov 2020 06:14:13 -0000
Newsgroups gmane.text.xml.xsl.general.mulberrytech
Message-ID <[email protected]>
 

Sent from my iPhone

> On Nov 24, 2020, at 9:15 PM, Liam R. E. Quin [email protected] <[email protected]> wrote:
> 
> On Wed, 2020-11-25 at 04:56 +0000, Dimitre Novatchev
> [email protected] wrote:
>> 
>> 
>> *The pure XPath solution is also an XQuery solution*, as XQuery is a
>> superset of XPath.
> 
> However, the results may differ in terms of in-scope namespaces, i
> think.
> 
> I'd probably write an XSLT function. Or an XQuery function.
> 
> Liam


This is a solution of the original problem. If we evolve the problem with specifying namespaces that should be in scope, this can also be done. 

I long for “almost impossible to solve problems” but this is not one of them. Examples can be found here: https://dnovatchev.wordpress.com

If one has an even small library of the right  XPath functions , say something corresponding to the (higher order) functions in just one or two core Haskell modules, these can be used to solve a large variety of problems.

As for using XQuery vs. XSLT, the problem of choosing one or the other doesn’t exist when using pure XPath.

Dimitre 

> 
> -- 
> Liam Quin, https://www.delightfulcomputing.com/
> Available for XML/Document/Information Architecture/XSLT/
> XSL/XQuery/Web/Text Processing/A11Y training, work & consulting.
> Barefoot Web-slave, antique illustrations:  http://www.fromoldbooks.org
> 
--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/3329386
or by email: [email protected]
--~--