Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Question on XSD elements in groups

From: Florent Georges <lists@--------.--->
To: Arshad Noor <arshad.noor@----------.--->, xmlschema-dev@--.---
Date: 6/23/2008 1:30:00 PM
Arshad Noor wrote:

  Hi,

> Since I can only have a Symkey, SymkeyError or a combination
> of both in the to-be-defined element, why does NB think there
> will be ambiguity?

  Because when it will encounter a Symkey, it will be not possible to
know in the choice if this is the Symkey from the Symkey alternative,
or from the group alternative.

> How do I go about accomplishing what I want?

  The idiomatic solution is to use a choice on Symkey and optional
SymkeyError, or just a SymkeyError:

    <xs:choice>
       <xs:sequence>
          <xs:element ref="Symkey"/>
          <xs:element ref="SymkeyError" minOccurs="0"/>
       </xs:sequence>
       <xs:sequence>
          <xs:element ref="SymkeyError"/>
       </xs:sequence>
    </xs:choice>

  For more information, look for "UPA" or "UPA violation".

  Regards,

--drkm
























      _____________________________________________________________________________ 
Envoyez avec Yahoo! Mail. Une boite mail plus intelligente http://mail.yahoo.fr

From koray.sakiroglu@g... Mon Jun 23 15:20:01 2008
Received: from farnsworth.w3.org ([12


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