[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Principles of XML design

xml whitespace between attributes significant
In article <0fa13582277ef91a61197ef274c686b8@r...> you write:

>I have, in fact, had the requirement for maintaining attribute order in 
>XML laid upon me more than once by people writing things like editors,

So what?  All languages - human languages, programming languages,
markup languages - have features that are not semantically significant,
but are preserved by editors for readability.  Objecting to XML editors
that change attribute order is like objecting to C code editors that
change the indentation: perfectly reasonable, but nothing to do with
whether it's significant in the language.

>The point here is that a *syntax* defines nothing more than the grammar 
>of a data format...

And XML is not *just* a syntax in that sense.  Some aspects of its
semantics are made explicit in the XML spec, some are omitted, and
some are left to the implementation.

>That the vast majority of XML tools works one way vs. another 
>is largely due to a shared understanding of processing model in the 
>community (which should be documented), not the grammar of XML.

You're right that it's not the grammar of XML, but XML is not
just the grammar.

>> You can of course construct even more egregious examples, such as a
>> format in which data is encoded by the number of spaces between
>> attributes.  That isn't XML.

>For some people it is. For some people, all whitespace is 
>significant... but again, that depends on the application aka. 
>processing model.

People for whom whitespace between attributes is significant *in
the application* are not using an XML application.

-- Richard


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.

Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.