XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Re: [xml-dev] The perils of using the @ symbol in JSON key name ...mapping JSON to XML, Schematron, XSLT, XPath, and/or XQuery

Hi Hans-Jürgen,

> Concerning the "cost" of transformation one should also remember the fact
> that the program works with an internal representation anyhow, not the
> document text. So one must take care not to confuse the mental
> transformation ("This is JSON, so to use it as XML I have to transform it,
> haven't I?") with any actual one - there is none, there is only a parsing of
> text into internal representation and a serialization of internal
> representation into text. So if the input is JSON text, treating it as XML
> only involves an *alternative* parsing and an *alternative* serialization,
> not any additional transformation.

You are making a very valid point here. The conversion can of course
be optimized to a direct "cross-parsing" to the desired memory representation.
Usually, the memory representation is supported by a data model such as the XDM
for XML.

However, this push-down functionality relies on the querying engine,
meaning that
one needs to find one that does so and with the required JSON-to-XML
mapping, or needs
to be able to tamper with the source code (but there are a few open-source
implementations out there).

I think another argument here for sticking to JSON data models and
querying languages
is to keep the technology stack lean and avoid gluing one's way
through impedance
mismatches as much as possible.

Kind regards,
Ghislain


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS