You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@xmlbeans.apache.org by Ramin Roham-Pour <rr...@ip-value.de> on 2006/03/03 15:48:20 UTC

substituting simple types

Hello!

I my schema it reads:

<complexType name="TroubleTicketValue" abstract="false">
   <complexContent>
      <extension base="co:ManagedEntityValue">
         <sequence>
            <element ref="tt:baseState" nillable="true" minOccurs="0"/>
         </sequence>
      </extension>
   </complexContent>
</complexType>

<element name="baseState" type="string"/>

<element name="troubleState" type="tt:TroubleState"
substitutionGroup="tt:baseState"/>

<simpleType name="TroubleState">
    <restriction base="string">
	<enumeration value="UNKNOWNTROUBLESTATE"/>
	<enumeration value="QUEUED"/>
	<enumeration value="OPENACTIVE"/>
	<enumeration value="DEFERRED"/>
	<enumeration value="CLEARED"/>
	<enumeration value="CLOSED"/>
	<enumeration value="DISABLED"/>
    </restriction>
</simpleType>

If I want to add a troubleState to a troubleTicketValue, I can only add
baseState. Parsing a document containing troubleState works fine, but
I'd like to build documents with troubleState without parsing it.
As troubleState is just a String I cannot use substitute(). Is there any
other way to solve this?

Regards
Ramin


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@xmlbeans.apache.org
For additional commands, e-mail: user-help@xmlbeans.apache.org