I have a problem redefining the xs:element in this way:
When i validate it, all goes well, but
when i try to use this schema to validate another schema and i try to validate it, the validator come out with problems with the previous valid schema.
Can someone help me?
Code:
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema"[/URL] xmlns="[URL unfurl="true"]http://www.giulio.org"[/URL] targetNamespace="[URL unfurl="true"]http://www.giulio.org"[/URL] elementFormDefault="qualified">
<xs:import namespace="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema"[/URL] schemaLocation="[URL unfurl="true"]http://www.w3.org/2001/XMLSchema.xsd"/>[/URL]
<xs:complexType name="elementType">
<xs:complexContent>
<xs:extension base="xs:element">
<xs:attribute name="mioattr" type="mioattrtype"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="mioattrtype">
<xs:restriction base="xs:string">
<xs:enumeration value="union"/>
<xs:enumeration value="disjunction"/>
<xs:enumeration value="overlap"/>
</xs:restriction>
</xs:simpleType>
<xs:element name="element" type="elementType"/>
</xs:schema>
When i validate it, all goes well, but
when i try to use this schema to validate another schema and i try to validate it, the validator come out with problems with the previous valid schema.
Can someone help me?