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] Six Reasons Not to use XML Attributes

While I agree it makes it bulkier, I disagree with the argument specifics. 
That is "looking ahead" is only a side effect of a particular parser implementation. 

i.e. 
if a parser reads


<thing 
   

It has to look ahead in both cases
A)   id="abc"
B)  ><id>abc<


It just happens that most XML parsers do this lookahead thing for you for attributes (and some do it for elements) ... but its not intrinsic in XML.




----------------------------------------
David A. Lee
dlee@calldei.com
http://www.xmlsh.org

> -----Original Message-----
> From: Andrew Welch [mailto:andrew.j.welch@gmail.com]
> Sent: Friday, March 02, 2012 9:15 AM
> To: Costello, Roger L.
> Cc: xml-dev@lists.xml.org
> Subject: Re: [xml-dev] Six Reasons Not to use XML Attributes
> 
> > 2.  Avoiding XML attributes makes your language simpler.
> 
> It really doesn't, it makes it bulkier and more annoying to process.
> 
> <thing type="A">
> 
> vs
> 
> <thing>
>   <type>A</type>
> 
> When processing <thing> you need to look ahead to determine how to
> process it.
> 
> 
> --
> Andrew Welch
> http://andrewjwelch.com
> 
> ______________________________________________________________
> _________
> 
> XML-DEV is a publicly archived, unmoderated list hosted by OASIS
> to support XML implementation and development. To minimize
> spam in the archives, you must subscribe before posting.
> 
> [Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/
> Or unsubscribe: xml-dev-unsubscribe@lists.xml.org
> subscribe: xml-dev-subscribe@lists.xml.org
> List archive: http://lists.xml.org/archives/xml-dev/
> List Guidelines: http://www.oasis-open.org/maillists/guidelines.php
> 




[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