If i have a type defined as
<xs:element name="serviceResponse">
<xs:complexType>
<xs:sequence>
<xs:element ref="status"/>
<xs:element ref="info"/>
<xs:element ref="code"/>
</xs:sequence>
</xs:complexType>
And would like to have an additional type that defined as
<xs:element name="serviceResponse">
<xs:complexType>
<xs:sequence>
<xs:element ref="status"/>
<xs:element ref="info"/>
<xs:element ref="code"/>
<xs:element ref="level"/>
</xs:sequence>
</xs:complexType>
</xs:element>
Is it possible to create a new type that extends the first type and only append the “level” element to the new type? (sort of like inheritance in Java)
It would be possible, if only the type of serviceResponse were a named type rather than anonymous: