XHTML basic1.1 (xhtml-basic11-modules-1.xsd file)的XML schema包含这样的重新定义:
<xs:redefine schemaLocation="http://www.w3.org/MarkUp/SCHEMA/xhtml-image-1.xsd">
<xs:annotation>
<xs:documentation>
Image module
Elements defined here:
* img
</xs:documentation>
<xs:documentation source="http://www.w3.org/TR/xhtml-modularization/abstract_modules.html#s_imagemodule"/>
</xs:annotation>
<xs:attributeGroup name="xhtml.img.attlist">
<xs:attributeGroup ref="xhtml.img.attlist">
<xs:annotation>
<xs:documentation>
Original Image Attributes (in Image Module)
</xs:documentation>
</xs:annotation>
</xs:attributeGroup>
</xs:attributeGroup>
</xs:redefine>这与简单地包含图像模块有什么不同吗?在我看来,它不会改变任何事情,但我不是XML Schema专家。
发布于 2012-03-25 07:05:20
我最初的回答是:
包括图像模块在内的
会将其中定义的所有内容都添加到模式中,而使用
xsd:redefine时,只会导入attributeGroup xhtml.img.attlist。
但事实并非如此-引用的模式中的所有内容都包含在内,因此答案似乎是没有理由使用该xsd:redefine。
https://stackoverflow.com/questions/9820866
复制相似问题