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

Re: What are the characteristics of a good type system for XML

characteristics of a good notation
Hi Arjun,

> Jeni Tennison <jeni@j...> wrote:
> | Finally, I think that there should be limits on the scope of a type
> | definition. XML types like ID and ENTITY have too wide a scope, in my
> | opinion, in that they specify constraints across entire documents as
> | well as on particular lexical representations.
> I don't understand the problem here.  Could you clarify?
> Declared values such as ID, NOTATION, IDREF and ENTITY (and the
> plurals of the last two) are just NAMEs, as far as "types" are
> concerned, it seems to me. Is this lexical form too constraining?
> For NOTATION and ENTITY, what purpose could a scope less than the
> document serve (given that referents are in the DTD rather than the
> instance)?

My point was that they're not just names. If you declare an attribute
as being of type ID, you not only say that the attribute must have a
value that meets the lexical constraints of being a name, you also say
that no other ID-type attribute in the document has the same value. If
you declare an attribute as being of type ENTITY, as well as stating
the format of the value of the attribute you state that there is an
unparsed entity declared in the DTD with that name. And so on for
NOTATION, IDREF and so on. They don't just constrain the value of the
attribute, they constrain other aspects of the document.

> I think the real problem is that declared values don't square with
> the usual notions of "type" (as in "data type"), so a type system of
> the kind under discussion should probably leave them out altogether
> except as just plain and simple NAMEs.

Yes, I agree. I think that the other kinds of constraints that these
types impose should be dealt with at a different level of validation.



Jeni Tennison


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.