OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   RE: Attr+: Integrating attributes and elements

[ Lists Home | Date Index | Thread Index ]
  • From: "Arnold, Curt" <Curt.Arnold@hyprotech.com>
  • To: "'xml-dev@ic.ac.uk'" <xml-dev@ic.ac.uk>
  • Date: Mon, 23 Aug 1999 09:52:01 -0600

It does have an initial appeal and I do use that type of construct
frequently, but I think it has some problems trying to build it into the
schema language.  If it is done at all, maybe it should really be an
Element-.  One of the key limitations of attributes is the inability to
support structure.  So I'm forced to make a transition to an element when I
need to add structured content, but I can use the attribute form when I
don't have any structured content.  The attribute can represent an element
that in this particular instance has no structured content.

Say, if I have a schema to communicate weather readings that reads something

	<location airportCode="IAH" temperature="33"/>

If I decided that I needed to add annotation to the temperature, I'd need to
support something like:

	<location airportCode="IAH">
		<temperature value="33">
			<note>Readings are delayed by 15 minutes</note>

My processing software could be smart enough to support either form.  So if
I didn't have a note to go with the reading I could use the attribute form.

However I'm not sure if I want the schema to have to define the map from the
element form to the attribute form or have the DOM produce a phantom element
for me.

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo@ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS