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] seduced by markup

On 11/16/2013 11:38 AM, Steve Newcomb wrote:
On 11/15/2013 10:10 PM, John Cowan wrote:

On Fri, Nov 15, 2013 at 4:32 PM, Steve Newcomb <srn@coolheads.com
<mailto:srn@coolheads.com>> wrote:

     The DTD syntax was never about machines.  It was about human beings, and
     it is still, even today, and as crummy as it is, the most humane way
     available for human beings to communicate about data design in a diverse
     collaborative environment that inevitably must include non-programmers.


In my opinion, RELAX NG compact syntax is far more humane than DTDs.  It
is as readable, if not more so; it has greater power; it has far fewer
arbitrary restrictions.
It is *more* readable for you and for me.  It is *less* readable for
those who haven't yet fully internalized that XML schemas are all about
element types.  For us,
Wow - Steve I love your analogy, but I think you may have fallen in love with it for its own sake, because it just doesn't apply to the DTD/RNC comparison, at least I don't see it. Now I may be a high priest and out of touch, but I just don't think DTDs are as transparent or accessible as you seem to think they are.

Years ago, as a relative newcomer to these technologies, I looked at DTD and RNC, and RNC made immediate, intuitive sense to me in a way that DTDs did not (and probably never will, because I doubt I'll spend enough time looking at them to get used to the squonks). Now that's a completely subjective assessment, but for example consider the alien words and tokens you have to learn to really get DTDs:

You have to understand that % is a magic letter that means the following token doesn't really mean anything about the markup, but is a reference to something defined elsewhere.

#IMPLIED (what does that mean? it seems to indicate there is a default value, but what is it?
NMTOKEN (hunh?)
CDATA (wha?)
PCDATA (seems to have something to with CDATA, but is it different in some subtle and important way?)
special meaning of ID/IDREF, but unfamiliar semantics (IDs can't be numbers! that will surprise a lot of people)
What is that PUBLIC identifier in the DOCTYPE declaration anyway? It often seems to have important-looking slashes and dashes in it, but why? Do I need to conform to some kind of slash-and-dash convention when inventing my own?

Contrived sure, and not all of these things are *necessary* in DTDs, but typically one does encounter them. Sure Relax has its own syntax to learn, but at its simplest, the RNG document structure *mirrors the structure of the document it models*, which to me is the thing that really makes it accessible and intuitive. I also like the relative lack of obscure words. And I have to say that most of the people that I work with have reacted in a similar way.

I like the idea that redundancy provides humans extra cues, but I'm just not sure DTD format in itself actually provides that. Comments in human languages are super helpful, as usual, but of course you can have comments in any schema format.

-Mike


[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