我正在尝试进行 xml 验证,但在进行 xml 验证时出现以下错误。
你能帮我吗,为什么我在验证时遇到错误
. 收到此错误“cvc-complex-type.2.4.a:发现以元素 'ObjectId' 开头的无效内容。应为“{LanguageCode}”之一。”
schema:
-------
<xs:complexType name="Paragraph">
<xs:sequence>
<xs:element name="ParagraphId" type="tns:ParagraphId" maxOccurs="unbounded" />
<xs:element minOccurs="0" name="Name" type="string"/>
<xs:element minOccurs="0" name="Description" type="string"/>
<xs:element minOccurs="0" name="SectionNumber" type="string"/>
<xs:element minOccurs="0" name="Editable" type="xs:boolean"/> <!-- If Y then This Paragraph is editable. -->
<xs:element minOccurs="0" name="ParagraphText" type="ref:swaRef"/>
<xs:element maxOccurs="1" minOccurs="0" name="Status" nillable="true" type="tns:StatusType"/>
<!-- retrieveParagraph() : List of variables of this paragraph and the following are retrieved based on this “ReturnVariable” flag. -->
<xs:element maxOccurs="unbounded" minOccurs="0" name="Variables" nillable="false" type="tns:Variable"/>
<xs:element minOccurs="0" name="OldParagraphId" type="tns:ParagraphId" maxOccurs="unbounded" /> <!-- It will be used to get effective time stamp of existing paragraph on which we are creating Modification -->
<xs:element minOccurs="0" name="Action" type="xs:string"/>
<xs:element minOccurs="0" name="LockedBy" type="string"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ParagraphId">
<xs:sequence>
<xs:element name="CountryCode" type="tns:CountryCodeType" />
<xs:element default="00" name="SubsidiaryCode" type="tns:SubsidiaryCodeType" />
<xs:element name="LanguageCode" type="string" />
<xs:element name="ObjectId" type="string" />
<xs:element name="TextVersionId" type="string" />
</xs:sequence>
</xs:complexType>
xml:
---
<Paragraphs>
<ParagraphId>
<CountryCode>111</CountryCode>
<SubsidiaryCode>01</SubsidiaryCode>
<LanguageCode>AAA</LanguageCode>
<ObjectId>MMMM</ObjectId>
<TextVersionId>1</TextVersionId>
</ParagraphId>
<Description>Title</Description>
<SectionNumber>2</SectionNumber>
<ParagraphText>cid:urn:uuid:FCA0989FBA745C0A771349097015870@apache.org</ParagraphText>
<Status>Draft</Status>
<OldParagraphId>
<CountryCode>111</CountryCode>
<SubsidiaryCode>01</SubsidiaryCode>
<ObjectId>1111</ObjectId>
<LanguageCode>ENU</LanguageCode>
<TextVersionId>1</TextVersionId>
</OldParagraphId>
</Paragraphs>