1
當我想驗證我的XSD文件,我得到這個錯誤違反了「唯一粒子屬性」
COS-nonambig:「我的XSD文件」:佈局和「我的XSD文件」:佈局(或要素從他們的替代組)違反了「獨特的粒子歸因」。在對這個模式進行驗證期間,將爲這兩個粒子創建模糊性。
,是指我這個標籤
<xs:complexType name="pageType">
<xs:choice>
<xs:element type="main:layoutType" name="layout" minOccurs="0" maxOccurs="1"/>
<xs:group ref="main:WidgetsGroup" maxOccurs="unbounded" minOccurs="0"/>
</xs:choice>
<xs:attribute type="xs:string" name="name"/>
<xs:attribute type="xs:string" name="layout"/>
<xs:attribute type="xs:string" name="dataModel"/>
<xs:attribute type="xs:string" name="domain"/>
</xs:complexType>
是什麼問題?我怎麼修復它?
請發表您的示例XML – 2012-07-09 06:26:40
驗證我的XSD文件時,這個錯誤引發,沒有任何XML文件 – Pooya 2012-07-09 06:28:46
它的發生是因爲我組標記包含與上述佈局標記衝突的佈局標記,並在從WidgetsGroup中移除佈局標記時解決。 – Pooya 2012-07-09 07:53:47