Xsd 0..*任意顺序的子元素,带有一个;任何;子元素
我试图以任何顺序拥有这些子元素中的任何一个。但我也希望考虑到任何额外的元素。当我添加一个未在选项列表中定义的新元素时,我得到一个验证错误“element下不允许使用element”Xsd 0..*任意顺序的子元素,带有一个;任何;子元素,xsd,Xsd,我试图以任何顺序拥有这些子元素中的任何一个。但我也希望考虑到任何额外的元素。当我添加一个未在选项列表中定义的新元素时,我得到一个验证错误“element下不允许使用element” 此版本的Atom模式基于1.0版的格式规范, 在这里找到http://www.atomenabled.org/developers/syndication/atom-format-spec.php. 一个Atom文档可能有两个根元素,feed和entry,如第2节所定义。 Atom提要构造在格式规范的第4.1
此版本的Atom模式基于1.0版的格式规范,
在这里找到http://www.atomenabled.org/developers/syndication/atom-format-spec.php.
一个Atom文档可能有两个根元素,feed和entry,如第2节所定义。
Atom提要构造在格式规范的第4.1.1节中定义。
默认情况下,不允许在文档中放入任何旧废话。它仍然需要解析器为该元素提供一个模式,并且必须根据该模式进行验证
如果要禁用该元素的验证,请使用processContents=“skip”
,即
<xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded" processContents="skip"/>
上有一个很好的processContents
描述,它比难以理解的XML模式规范清晰得多
<xsd:complexType name="feedType">
<xsd:annotation>
<xsd:documentation>
The Atom feed construct is defined in section 4.1.1 of the format spec.
</xsd:documentation>
</xsd:annotation>
<xsd:choice minOccurs="3" maxOccurs="unbounded">
<xsd:element name="author" type="atom:personType" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="category" type="atom:categoryType" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="contributor" type="atom:personType" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="generator" type="atom:generatorType" minOccurs="0" maxOccurs="1" />
<xsd:element name="icon" type="atom:iconType" minOccurs="0" maxOccurs="1" />
<xsd:element name="id" type="atom:idType" minOccurs="1" maxOccurs="1" />
<xsd:element name="link" type="atom:linkType" minOccurs="0" maxOccurs="unbounded" />
<xsd:element name="logo" type="atom:logoType" minOccurs="0" maxOccurs="1" />
<xsd:element name="rights" type="atom:textType" minOccurs="0" maxOccurs="1" />
<xsd:element name="subtitle" type="atom:textType" minOccurs="0" maxOccurs="1" />
<xsd:element name="title" type="atom:textType" minOccurs="1" maxOccurs="1" />
<xsd:element name="updated" type="atom:dateTimeType" minOccurs="1" maxOccurs="1" />
<xsd:element name="entry" type="atom:entryType" minOccurs="0" maxOccurs="unbounded" />
<xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded"/>
</xsd:choice>
<xsd:attributeGroup ref="atom:commonAttributes"/>
</xsd:complexType>
<xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded" processContents="skip"/>