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

Re: Why does XML Schema allow elements with complex type tobe

  • From: "Costello, Roger L." <costello@mitre.org>
  • To: xml-dev <xml-dev@lists.xml.org>
  • Date: Mon, 15 Jul 2019 11:59:39 +0000

Re:  Why does XML Schema allow elements with complex type tobe

Hi Folks,

 

Here are three XML representations for the name John Doe:

 

<Name>
   
<First>John</First>
   
<Middle xsi:nil="true"></Middle>
   
<Last>Doe</Last>
</Name>

<Name>
   
<First>John</First>
   
<Middle></Middle>
   
<Last>Doe</Last>
</Name>

<Name>
   
<First>John</First>
   
<Last>Doe</Last>
</Name>

 

Description #1

Rick says that the first XML representation – with xsi:nil="true" – does not disclose whether John Doe has a middle name or not. The reason for not disclosing may be because the author of the XML doesn't know John Doe’s middle name, or the requestor of the XML didn't ask for John Doe’s middle name, or the author of the XML doesn’t want to tell.

 

Description #2

Rick says that the last XML representation – no <Middle> element – indicates that John Doe has no middle name.

 

Description #3

What does the second XML representation – empty <Middle> element – denote?

 

Notice that the descriptions state the meaning of the XML:

 

  • The first XML representation means John Doe’s middle name is not being disclosed.
  • The last XML representation means John Doe does not have a middle name.
  • Uncertain about the meaning of the second XML representation.

 

In Rick’s most recent post, he states:

 

  1. XML does not have meaning. The three XML representations do not mean, denote, or indicate anything.
  2. Core to XML is the separation of syntax (markup) and meaning (how to interpret and process the syntax)

 

Rick advises against using xsi:nil

 

Rick, have I accurately captured your thoughts?

 

/Roger



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


PURCHASE STYLUS STUDIO ONLINE TODAY!

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.
Email
First Name
Last Name
Company
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.