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

RE: RELAX NG Marketing (was RE: Do Names Matter?)

RE:  RELAX NG Marketing (was RE:  Do Names Matter?)
> > I'm not entirely sure what the objection to this is. 
> Wouldn't it make more
> > sense to default an empty element than to insert the 
> element automatically
> > (which could be taken care of by setting the minimum 
> occurrence to one)?
> How would setting the minimum occurrence to one automatically 
> insert the
> element along with its value?

Well, we're supposing that there are two alternatives for element defaulting
(besides just ditching the whole idea): 1) default empty elements or 2)
default non-present elements. If the latter is desired, it can be
"simulated" with the former by setting the minimum occurrence value to one.

> Support for attribute defaulting is arguably desirable 
> because there is a
> long-established practice of doing it and people have got 
> used to depending
> on it.  There is no such well-established practice for 
> element defaulting.
> What is the compelling use case for being able to specify an 
> empty element
> in the instance and have the validator insert a value specified in the
> schema?  This is not at all the same kind of thing as 
> attribute defaulting
> and the existing practice of attribute defaulting provides no 
> justification
> for such a feature. Why should this one particular kind of 
> transformation be
> specified in a schema?

I guess the only case for this is that elements should be on the same
footing as attributes. Anyway, I've been pretty much convinced by the notion
that the "special status" of attribute defaulting is an unfortunately
vestige of older markup variants (not mentioning any names here) and should
be replaced by a general purpose transformation approach.



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.