XMLスキーマの制限によって派生物を作成しようとしていますが、動作させることができません。私は、私たちが派生した場所からベースの内容を書き直すことを義務付けられていますが、私はそれを行ったと思いますが、問題が何かを見つけることができません。XML - パーティクル間に完全な機能マッピングがありません
検証エラー:
Not valid.
Error - Line 60, 41: org.xml.sax.SAXParseException; lineNumber: 60; columnNumber: 41; rcase-Recurse.2: There is not a complete functional mapping between the particles.
Error - Line 60, 41: org.xml.sax.SAXParseException; lineNumber: 60; columnNumber: 41; derivation-ok-restriction.5.4.2: Error for type 'seminarType'. The particle of the type is not a valid restriction of the particle of the base.
Error - Line 104, 37: org.xml.sax.SAXParseException; lineNumber: 104; columnNumber: 37; rcase-Recurse.2: There is not a complete functional mapping between the particles.
Error - Line 104, 37: org.xml.sax.SAXParseException; lineNumber: 104; columnNumber: 37; derivation-ok-restriction.5.4.2: Error for type 'labType'. The particle of the type is not a valid restriction of the particle of the base.
XSDコード:
<?xml version="1.0"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
targetNamespace="schedule"
xmlns="schedule"
elementFormDefault="qualified">
<xsd:element name="Event" type="eventType"/>
<xsd:complexType name="eventType">
<xsd:sequence>
<xsd:element name="Title" type="xsd:string"/>
<xsd:element name="Lecture" minOccurs="1" maxOccurs="9">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Day">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Monday"/>
<xsd:enumeration value="Tuesday"/>
<xsd:enumeration value="Wednesday"/>
<xsd:enumeration value="Thursday"/>
<xsd:enumeration value="Friday"/>
<xsd:enumeration value="Saturday"/>
<xsd:enumeration value="Sunday"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="Time">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:length value="11"/>
<xsd:pattern value="[0-2][0-9]:[0-5][0-9]-[0-2][0-9]:[0-5][0-9]"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:sequence>
<xsd:attribute name="Classroom" use="required">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="7"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:attribute>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="lessonType">
<xsd:complexContent>
<xsd:extension base="eventType">
<xsd:sequence>
<xsd:element name="Professor" type="xsd:string"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="seminarType">
<xsd:complexContent>
<xsd:restriction base="eventType">
<xsd:sequence>
<xsd:element name="Title" type="xsd:string"/>
<xsd:element name="Lecture" minOccurs="1" maxOccurs="9">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Day">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Monday"/>
<xsd:enumeration value="Tuesday"/>
<xsd:enumeration value="Wednesday"/>
<xsd:enumeration value="Thursday"/>
<xsd:enumeration value="Friday"/>
<xsd:enumeration value="Saturday"/>
<xsd:enumeration value="Sunday"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="Time">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:length value="11"/>
<xsd:pattern value="[0-2][0-9]:[0-5][0-9]-[0-2][0-9]:[0-5][0-9]"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:sequence>
<xsd:attribute name="Classroom" use="required">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="7"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:attribute>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="labType">
<xsd:complexContent>
<xsd:restriction base="eventType">
<xsd:sequence>
<xsd:element name="Title" type="xsd:string"/>
<xsd:element name="Lecture" minOccurs="1" maxOccurs="9">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Day">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Monday"/>
<xsd:enumeration value="Tuesday"/>
<xsd:enumeration value="Wednesday"/>
<xsd:enumeration value="Thursday"/>
<xsd:enumeration value="Friday"/>
<xsd:enumeration value="Saturday"/>
<xsd:enumeration value="Sunday"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="Time">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:length value="11"/>
<xsd:pattern value="[0-2][0-9]:[0-5][0-9]-[0-2][0-9]:[0-5][0-9]"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
</xsd:sequence>
<xsd:attribute name="Classroom" use="required">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="7"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:attribute>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
</xsd:schema>