Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: SV: SV: empty elements and xsd:string

From: ht@---.--.--.-- (----- -. --------)
To: Bryan Rasmussen <brs@----.-->
Date: 2/21/2005 5:15:00 PM
I'm not sure I follow.

text nodes and element values are not the same thing, you're mixing
the XPath data model and the XML Infoset (and how W3C XML Schema uses
the Infoset).

Consider your example

 <tag><hi>  </hi><hi></hi><hi/></tag>

The starting point for validation for all simple types is the *initial
value* of the element or attribute information item in question [1]:

  [T]he *initial value* of an element information item is the string
  composed of, in order, the [character code] of each character
  information item in the [children] of that element information item.

So in your example we get one string with two characters and two
strings with no characters (the empty string).  The second and third
'hi' elements in your example are treated identically, _because they
are identical at the Infoset level_.

Are you suggesting that the empty string is not a string, or rather
that it should not have been a member of xs:string?  I think that
would violate many more expectations than including it, as the REC
does.

Or are you suggesting that the Infoset is wrong in failing to
distinguish the second and third 'hi' elements above?

ht

[1] http://www.w3.org/TR/xmlschema-1/#key-iv
-- 
 Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
                     Half-time member of W3C Team
    2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
            Fax: (44) 131 650-4587, e-mail: ht@i...
                   URL: http://www.ltg.ed.ac.uk/~ht/
[mail really from me _always_ has this .sig -- mail without it is forged spam]

From mike@s... Mon Feb 21 17:37:10 2005
Received: from lisa.w3.org ([


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent