|
|
<simpleType name='sizes'> <list itemType='decimal'/> </simpleType>
<cerealSizes xsi:type='sizes'>8 10.5 12</cerealSizes>
<simpleType name='listOfString'> <list itemType=“字符串”/> </simpleType>
<someElement xsi:type='listOfString'> 这不是列表项1 这不是清单项目2 这不是清单项目3 </someElement>
<xs:simpleType name='myList'> <xs:list itemType='xs:integer'/> </xs:simpleType> <xs:simpleType name='myRestrictedList'> <xs:restriction base='myList'> <xs:pattern value='123(\d+\s)*456'/> </xs:restriction> </xs:simpleType> 123 456 <someElement xsi:type='myRestrictedList'>123 987 456</someElement> 123 987 567 456
<attributeGroup name=“occurs”> <attribute name=“minOccurs”type=“nonNegativeInteger” use=“optional”default=“1”/> <attribute name=“maxOccurs”use=“optional”default=“1”> <simpleType> <联合> <simpleType> <restriction base='nonNegativeInteger'/> </simpleType> <simpleType> <限制基=“字符串”> <枚举值=“unbounded”/> </限制> </simpleType> </联合> </simpleType> </属性> </attributeGroup(属性组)>
The order in which the
<xsd:element name='size'> <xsd:simpleType> <xsd:union(联合)> <xsd:simpleType> <xsd:restriction base='integer'/> </xsd:simpleType> <xsd:simpleType> <xsd:restriction base='string'/> </xsd:simpleType> </xsd:union> </xsd:simpleType> </xsd:element>
<size>1</size> <size>大</size> <size xsi:type='xsd:string'>1</size>
http://www.w3.org/2001/XMLSchema#int
http://www.w3.org/2001/XMLSchema#maxInclusive(http://www.w3.org/2001/XMLSchema#maxInclusive)
http://www.w3.org/2001/XMLSchema#int.maxInclusive(包含)
YYYY年
不锈钢
<simpleType name='SQL-Year-Month-Interval'> <限制基数=“持续时间”> <模式值='P\P{Nd} {4} Y(Y) \p{Nd} {2} M(M) '/> </限制> </simpleType>
'-'
24
0
Z轴
simpleType(简单类型)
限制
列表
<simpleType name='listOfFloat'> <list itemType='float'/> </simpleType>
联盟
<xsd:attribute name=“size”> <xsd:simpleType> <xsd:union(联合)> <xsd:simpleType> <xsd:restriction base=“xsd:positiveInteger”> <xsd:minInclusive value=“8”/> <xsd:maxInclusive value=“72”/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType> <xsd:restriction base=“xsd:NMTOKEN”> <xsd:enumeration value=“small”/> <xsd:enumeration value=“medium”/> <xsd:enumeration value=“large”/> </xsd:restriction> </xsd:simpleType> </xsd:union> </xsd:simpleType> </xsd:attribute>
<p> 标题 </p> <p> 这是一个测试 </p>
<simpleType name='productCode'> <限制基=“字符串”> <长度值='8'固定='true'/> </限制> </simpleType>
<simpleType name='no-empty-string'> <限制基=“字符串”> <minLength值=“1”/> </限制> </simpleType>
<simpleType name='form-input'> <限制基=“字符串”> <maxLength值='50'/> </限制> </simpleType>
<simpleType name='better-us-zipcode'> <限制基=“字符串”> <模式值=“[0-9]{5}(-[0-9]})?”/> </限制> </simpleType>
<simpleType name=“假日”> <注释> <文档>一些美国假日</documentation> </注释> <限制基数='gMonthDay'> <枚举值='--01-01'> <注释> <文档>元旦</documentation> </注释> </枚举> <枚举值=“--07-04”> <注释> <documentation>7月4日</documentation> </注释> </枚举> <枚举值='--12-25'> <注释> <文档>圣诞节</documentation> </注释> </枚举> </限制> </simpleType>
<simpleType name='token'> <restriction base='normalizedString'> <whiteSpace value='collapse'/> </限制> </simpleType>
<simpleType name='one-hundred-or-less'> <限制基数=‘整数’> <maxInclusive value='100'/> </限制> </simpleType>
<simpleType name='less-than-one-fundred-and-one'> <限制基数=‘整数’> <maxExclusive value='101'/> </限制> </simpleType>
<simpleType name='more-than-ninety-9en'> <限制基数=‘整数’> <minExclusive值='99'/> </限制> </simpleType>
<simpleType name='one-hundred-or-more'> <限制基数=‘整数’> <minInclusive value='100'/> </限制> </simpleType>
<simpleType name='celsiusBodyTemp'> <限制基数='decimal'> <totalDigits value='4'/> <fractionDigits value='1'/> <minInclusive值=“36.4”/> <maxInclusive value='40.5'/> </限制> </simpleType>
<! DOCTYPE xs:schema PUBLIC“-//W3C//DTD XMLSCHEMA 200102//EN”“XMLSCHEMA.DTD”[ <!-- 保持此模式XML1.0 DTD有效 --> <! ENTITY%schemaAttrs的xmlns:hfp CDATA#IMPLIED'> <! 元素hfp:hasFacet为空> <! ATTLIST hfp:hasFacet(附件hfp) name NMTOKEN#REQUIRED(名称NMTOKEN#必需)> <! ELEMENT hfp:hasProperty EMPTY>元素hfp:hasProperty空> <! ATTLIST hfp:hasProperty(附件hfp) name NMTOKEN#必需 value CDATA#必需> <!-- 确保不读取外部 子集将了解我们声明的各种ID --> <! ATTLIST xs:simpleType id id#IMPLIED> <! ATTLIST xs:maxExclusive id id#IMPLIED> <! ATTLIST xs:minExclusive id id#IMPLIED> <! ATTLIST xs:maxInclusive id id#隐含> <! ATTLIST xs:minInclusive id id#IMPLIED> <! ATTLIST xs:totalDigits id id#IMPLIED> <! ATTLIST xs:fractionDigits id id#IMPLIED> <! ATTLIST xs:length id id#IMPLIED> <! ATTLIST xs:minLength id id#IMPLIED> <! ATTLIST xs:maxLength id id#IMPLIED> <! ATTLIST xs:枚举id#IMPLIED> <! ATTLIST xs:pattern id id#IMPLIED> <! ATTLIST xs:appinfo id id#隐含> <! ATTLIST xs:文档id#IMPLIED> <! ATTLIST xs:list id id#隐含> <! ATTLIST xs:联合id#IMPLIED> ]> <? xml版本=“1.0”?> <xs:schema xmlns:hfp=“ http://www.w3.org/2001/XMLSchema-hasFacetAndProperty网站 " xmlns:xs=“ http://www.w3.org/2001/XMLSchema(http://www.w3.org/2001/XMLSchema) “blockDefault=”#all“ elementFormDefault=“qualified”xml:lang=“en” targetNamespace=“ http://www.w3.org/2001/XMLSchema(http://www.w3.org/2001/XMLSchema) " version=“Id:datatypes.xsd,v 1.4 2004/05/29 10:26:33 ht Exp”> <xs:annotation> <xs:documentation source=“../datatypes/datatypes-with-errata.html”> 与本文件相对应的模式是规范的, 关于它在 XML模式语言。 文档(在<;documentation>中 元素),不是规范性的,而是强调了重要的 这是W3C建议书的一部分 </xs:documentation> </xs:annotation> <xs:annotation> <xs:documentation> 首先是内置的原始数据类型。 这些定义适用于 只有信息,真正的内置定义才是神奇的。 </xs:documentation> <xs:documentation> 对于此模式中的每个内置数据类型(原语和 派生的)可以通过构造的URI唯一寻址 如下: 1) 基本URI是XML架构命名空间的URI 2) 片段标识符是数据类型的名称 例如,要处理int数据类型,URI为: http://www.w3.org/2001/XMLSchema#int 此外,每个方面定义元素可以是唯一的 通过如下构造的URI寻址: 1) 基本URI是XML架构命名空间的URI 2) 片段标识符是方面的名称 例如,要处理maxInclusive方面,URI是: http://www.w3.org/2001/XMLSchema#maxInclusive(http://www.w3.org/2001/XMLSchema#maxInclusive) 此外,内置数据类型定义中的每个方面的用法 可以通过如下构造的URI进行唯一寻址: 1) 基本URI是XML架构命名空间的URI 2) 片段标识符是数据类型的名称,后跟 由句点(“.”)后跟方面的名称 例如,要解决中maxInclusive方面的用法 int的定义,URI为: http://www.w3.org/2001/XMLSchema#int.maxInclusive(包含) </xs:documentation> </xs:annotation> <xs:simpleType name=“string”id=“string“> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#string "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace value=“preserve”id=“string.preserve”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“boolean”id=“booleal”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“finited”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#boolean "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“boolean.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“float”id=“float“> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“true”/> <hfp:hasProperty name=“cardinality”value=“finited”/> <hfp:hasProperty name=“numeric”value=“true”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#float "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“float.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“double”id=“doubel”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“true”/> <hfp:hasProperty name=“cardinality”value=“finited”/> <hfp:hasProperty name=“numeric”value=“true”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#double "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“double.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“decimal”id=“decical”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“totalDigits”/> <hfp:hasFacet name=“fractionDigits”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“total”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“true”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#decimal网站 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“decimal.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“duration”id=“duration”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#duration "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“duration.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“dateTime”id=“dateTime”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#dateTime(http://www.w3.org/TR/xmlschema-2/#dateTime) "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“dateTime.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“time”id=“time“> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#time网站 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“time.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“date”id=“date”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#日期 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“date.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“gYearMonth”id=“gYearMonth”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#gYearMonth网址 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“gYearMonth.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“gYear”id=“gYear> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#gYear "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“gYear.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“gMonthDay”id=“gMonhDay”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#gMonthDay网站 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“gMonthDay.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“gDay”id=“gDay> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#gDay网站 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“gDay.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“gMonth”id=“gMonth”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“maxInclusive”/> <hfp:hasFacet name=“maxExclusive”/> <hfp:hasFacet name=“minInclusive”/> <hfp:hasFacet name=“minExclusive”/> <hfp:hasProperty name=“ordered”value=“partial”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#gMonth网站 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“gMonth.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“hexBinary”id=“hex二进制”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#binary "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“hexBinary.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“base64Binary”id=“base64二进制”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#base64二进制 "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“base64Binary.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“anyURI”id=“anyURL”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#anyURI "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“anyURI.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“QName”id=“QName”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#QName "/> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“QName.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“NOTATION”id=“NOTAITION”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“pattern”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#NOTATION(注释) "/> <xs:documentation> NOTATION不能直接在模式中使用; 而是一种类型 必须通过指定至少一个枚举从中派生 其值是在 模式。 </xs:documentation> </xs:annotation> <xs:restriction base=“xs:anySimpleType”> <xs:whiteSpace fixed=“true”value=“collapse”id=“NOTATION.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:annotation> <xs:documentation> 现在派生的基元类型 </xs:documentation> </xs:annotation> <xs:simpleType name=“normalizedString”id=“normalistedString”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#normalizedString(http://www.w3.org/TR/xmlschema-2/#normalizedString) "/> </xs:annotation> <xs:restriction base=“xs:string”> <xs:whiteSpace value=“replace”id=“normalizedString.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“token”id=“token> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#令牌 "/> </xs:annotation> <xs:restriction base=“xs:normalizedString”> <xs:whiteSpace value=“collapse”id=“token.whiteSpace”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“language”id=“language> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#语言 "/> </xs:annotation> <xs:restriction base=“xs:token”> <xs:pattern value=“[a-zA-Z]{1,8}(-[a-zA-Z0-9]{1,8})*” id=“language.pattern”> <xs:annotation> <xs:documentation source=“ http://www.ietf.org/rfc/rfc3066.txt "> 模式指定了XML1.0e2第2.12节的内容 和RFC 3066(RFC 1766的修订版)。 </xs:documentation> </xs:annotation> </xs:pattern> </xs:restriction> </xs:simpleType> <xs:simpleType name=“IDREFS”id=“IDREWS”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“pattern”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#IDREFS "/> </xs:annotation> <xs:restriction> <xs:simpleType> <xs:list itemType=“xs:IDREF”/> </xs:simpleType> <xs:minLength value=“1”id=“IDREFS.minLength”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“ENTITIES”id=“ENTITES”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“pattern”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#ENTITIES(实体) "/> </xs:annotation> <xs:restriction> <xs:simpleType> <xs:list itemType=“xs:ENTITY”/> </xs:simpleType> <xs:minLength value=“1”id=“ENTITIES.minLengh”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“NMTOKEN”id=“NMTOKEN”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#NMTOKEN网站 "/> </xs:annotation> <xs:restriction base=“xs:token”> <xs:pattern value=“\c+”id=“NMTOKEN.pattern”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/REC-xml#NT -Nmtoken“> 模式与XML规范中的production 7相匹配 </xs:documentation> </xs:annotation> </xs:pattern> </xs:restriction> </xs:simpleType> <xs:simpleType name=“NMTOKENS”id=“NMTOKENS”> <xs:annotation> <xs:appinfo> <hfp:hasFacet name=“length”/> <hfp:hasFacet name=“minLength”/> <hfp:hasFacet name=“maxLength”/> <hfp:hasFacet name=“enumeration”/> <hfp:hasFacet name=“whiteSpace”/> <hfp:hasFacet name=“pattern”/> <hfp:hasProperty name=“ordered”value=“false”/> <hfp:hasProperty name=“bounded”value=“false”/> <hfp:hasProperty name=“cardinality”value=“countably infinite”/> <hfp:hasProperty name=“numeric”value=“false”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#NMTOKENS "/> </xs:annotation> <xs:restriction> <xs:simpleType> <xs:list itemType=“xs:NMTOKEN”/> </xs:simpleType> <xs:minLength value=“1”id=“NMTOKENS.minLength”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“name”id=“name”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#名称 "/> </xs:annotation> <xs:restriction base=“xs:token”> <xs:pattern value=“\i\c*”id=“Name.pattern”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/REC-xml#NT -名称“> 模式匹配XML规范中的产品5 </xs:documentation> </xs:annotation> </xs:pattern> </xs:restriction> </xs:simpleType> <xs:simpleType name=“NCName”id=“NCName“> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#NCName "/> </xs:annotation> <xs:restriction base=“xs:Name”> <xs:pattern value=“[\i-[:]][\c-[:]]*”id=“NCName.pattern”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/REC-xml-names/#NT -NCName“> 模式匹配XML规范中命名空间的产品4 </xs:documentation> </xs:annotation> </xs:pattern> </xs:restriction> </xs:simpleType> <xs:simpleType name=“ID”ID=“ID”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#ID "/> </xs:annotation> <xs:restriction base=“xs:NCName”/> </xs:simpleType> <xs:simpleType name=“IDREF”id=“IDREV”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#IDREF "/> </xs:annotation> <xs:restriction base=“xs:NCName”/> </xs:simpleType> <xs:simpleType name=“ENTITY”id=“ENTITY”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#ENTITY(http://www.w3.org/TR/xmlschema-2/#ENTITY) "/> </xs:annotation> <xs:restriction base=“xs:NCName”/> </xs:simpleType> <xs:simpleType name=“integer”id=“intege”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#integer "/> </xs:annotation> <xs:restriction base=“xs:decimal”> <xs:fractionDigits-fixed=“true”value=“0”id=“integer.refctionDigits”/> <xs:pattern value=“[\-+]?[0-9]+”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“nonPositiveInteger”id=“nonpositiveIntegrer”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#nonPositiveIntegrer网站 "/> </xs:annotation> <xs:restriction base=“xs:integer”> <xs:maxInclusive value=“0”id=“nonPositiveInteger.maxInclusive”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“negativeIntegrer”id=“negateIntegrer”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#negativeInteger(http://www.w3.org/TR/xmlschema-2/#negativeInteger) "/> </xs:annotation> <xs:restriction base=“xs:nonPositiveIntegrer”> <xs:maxInclusive value=“-1”id=“negativeInteger.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“long”id=“long“> <xs:annotation> <xs:appinfo> <hfp:hasProperty name=“bounded”value=“true”/> <hfp:hasProperty name=“cardinality”value=“finited”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#long "/> </xs:annotation> <xs:restriction base=“xs:integer”> <xs:minInclusive value=“-9223372036854775808”id=“long.minInclustive”/> <xs:maxInclusive value=“9223372036854775807”id=“long.maxInclustive”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“int”id=“int”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#int "/> </xs:annotation> <xs:restriction base=“xs:long”> <xs:minInclusive value=“-2147483648”id=“int.minInclusie”/> <xs:maxInclusive value=“2147483647”id=“int.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“short”id=“short“> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#short "/> </xs:annotation> <xs:restriction base=“xs:int”> <xs:minInclusive value=“-32768”id=“short.minInclusive”/> <xs:maxInclusive value=“32767”id=“short.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“字节”id=“字节”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#byte "/> </xs:annotation> <xs:restriction base=“xs:short”> <xs:minInclusive value=“-128”id=“byte.minClusive”/> <xs:maxInclusive value=“127”id=“byte.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“nonNegativeInteger”id=“nonNegativeInteger”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#nonNegativeInteger "/> </xs:annotation> <xs:restriction base=“xs:integer”> <xs:minInclusive value=“0”id=“nonNegativeInteger.minClusive”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“unsignedLong”id=“unsinnedLong”> <xs:annotation> <xs:appinfo> <hfp:hasProperty name=“bounded”value=“true”/> <hfp:hasProperty name=“cardinality”value=“finited”/> </xs:appinfo> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#unsignedLong "/> </xs:annotation> <xs:restriction base=“xs:nonNegativeInteger”> <xs:maxInclusive value=“18446744073709551615” id=“unsignedLong.maxInclusive”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“unsignedInt”id=“unsinnedInt”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#unsignedInt网址 "/> </xs:annotation> <xs:restriction base=“xs:unsignedLong”> <xs:maxInclusive value=“4294967295”id=“unsignedInt.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“unsignedShort”id=“unsignedShort”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#unsignedShort "/> </xs:annotation> <xs:restriction base=“xs:unsignedInt”> <xs:maxInclusive value=“65535”id=“unsignedShort.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“unsignedByte”id=“unsinnedByte”> <xs:annotation> <xs:documentation source=“ http://www.w3.org/TR/xmlschema-2/#unsignedByte "/> </xs:annotation> <xs:restriction base=“xs:unsignedShort”> <xs:maxInclusive value=“255”id=“unsignedByte.maxInclusite”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“positionveInteger”id=“positiveIntege”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#positiveInteger "/> </xs:annotation> <xs:restriction base=“xs:nonNegativeInteger”> <xs:minInclusive value=“1”id=“positiveInteger.minClusive”/> </xs:restriction> </xs:simpleType> <xs:simpleType name=“derivationControl”> <xs:annotation> <xs:documentation> 实用程序类型,不供公共使用</xs:documentation> </xs:annotation> <xs:restriction base=“xs:NMTOKEN”> <xs:enumeration value=“substitution”/> <xs:enumeration value=“extension”/> <xs:enumeration value=“restriction”/> <xs:enumeration value=“list”/> <xs:enumeration value=“union”/> </xs:restriction> </xs:simpleType> <xs:group name=“simpleDerivation”> <xs:choice> <xs:element ref=“xs:restriction”/> <xs:element ref=“xs:list”/> <xs:element ref=“xs:union”/> </xs:choice> </xs:group> <xs:simpleType name=“simpleDerivationSet”> <xs:annotation> <xs:documentation> #{restriction,union,list}的全部或(可能为空)子集 </xs:documentation> <xs:documentation> 实用程序类型,不供公共使用</xs:documentation> </xs:annotation> <xs:union(联合)> <xs:simpleType> <xs:restriction base=“xs:token”> <xs:enumeration value=“#all”/> </xs:restriction> </xs:simpleType> <xs:simpleType> <xs:list> <xs:simpleType> <xs:restriction base=“xs:derivationControl”> <xs:enumeration value=“list”/> <xs:enumeration value=“union”/> <xs:enumeration value=“restriction”/> </xs:restriction> </xs:simpleType> </xs:list> </xs:simpleType> </xs:union(联合)> </xs:simpleType> <xs:complexType name=“simpleType”abstract=“true”> <xs:complexContent> <xs:extension base=“xs:annotated”> <xs:group ref=“xs:simpleDerivation”/> <xs:attribute name=“final”type=“xs:simpleDerivationSet”/> <xs:attribute name=“name”type=“xs:NCName”> <xs:annotation> <xs:documentation> 可以限制为要求或禁止 </xs:documentation> </xs:annotation> </xs:attribute> </xs:extension> </xs:complexContent> </xs:complexType> <xs:complexType name=“topLevelSimpleType”> <xs:complexContent> <xs:restriction base=“xs:simpleType”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> <xs:group ref=“xs:simpleDerivation”/> </xs:sequence> <xs:attribute name=“name”type=“xs:NCName”use=“required”> <xs:annotation> <xs:documentation> 顶层需要 </xs:documentation> </xs:annotation> </xs:attribute> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> <xs:complexType name=“localSimpleType”> <xs:complexContent> <xs:restriction base=“xs:simpleType”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> <xs:group ref=“xs:simpleDerivation”/> </xs:sequence> <xs:attribute name=“name”use=“probited”> <xs:annotation> <xs:documentation> 嵌套时禁止 </xs:documentation> </xs:annotation> </xs:attribute> <xs:attribute name=“final”use=“probited”/> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> <xs:element name=“simpleType”type=“xs:topLevelSimpleType”id=“simpletType”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -simpleType“/> </xs:annotation> </xs:element> <xs:group name=“facets”> <xs:annotation> <xs:documentation> 我们应该使用facet的替换组,但是 这被排除在外,因为它允许用户 添加他们自己的,我们还没有准备好。 </xs:documentation> </xs:annotation> <xs:choice> <xs:element ref=“xs:minExclusive”/> <xs:element ref=“xs:minInclusive”/> <xs:element ref=“xs:maxExclusive”/> <xs:element ref=“xs:maxInclusive”/> <xs:element ref=“xs:totalDigits”/> <xs:element ref=“xs:fractionDigits”/> <xs:element ref=“xs:length”/> <xs:element ref=“xs:minLength”/> <xs:element ref=“xs:maxLength”/> <xs:element ref=“xs:enumeration”/> <xs:element ref=“xs:whiteSpace”/> <xs:element ref=“xs:pattern”/> </xs:choice> </xs:group> <xs:group name=“simpleRestrictionModel”> <xs:sequence> <xs:element name=“simpleType”type=“xs:localSimpleType”minOccurs=“0”/> <xs:group ref=“xs:facets”minOccurs=“0”maxOccurs=“unbounded”/> </xs:sequence> </xs:group> <xs:element name=“restriction”id=“restriction”> <xs:complexType> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -限制“> 基本属性和simpleType子级是相互的 独占,但需要一个或另一个 </xs:documentation> </xs:annotation> <xs:complexContent> <xs:extension base=“xs:annotated”> <xs:group ref=“xs:simpleRestrictionModel”/> <xs:attribute name=“base”type=“xs:QName”use=“optional”/> </xs:extension> </xs:complexContent> </xs:complexType> </xs:element> <xs:element name=“list”id=“list“> <xs:complexType> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -列表“> itemType属性和simpleType子级是相互的 独占,但需要一个或另一个 </xs:documentation> </xs:annotation> <xs:complexContent> <xs:extension base=“xs:annotated”> <xs:sequence> <xs:element name=“simpleType”type=“xs:localSimpleType” 最小发生次数=“0”/> </xs:sequence> <xs:attribute name=“itemType”type=“xs:QName”use=“optional”/> </xs:extension> </xs:complexContent> </xs:complexType> </xs:element> <xs:element name=“union”id=“union“> <xs:complexType> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -工会“> memberTypes属性必须为非空或必须有 至少一个simpleType子级 </xs:documentation> </xs:annotation> <xs:complexContent> <xs:extension base=“xs:annotated”> <xs:sequence> <xs:element name=“simpleType”type=“xs:localSimpleType” minOccurs=“0”maxOccurs=“无界”/> </xs:sequence> <xs:attribute name=“memberTypes”use=“optional”> <xs:simpleType> <xs:list itemType=“xs:QName”/> </xs:simpleType> </xs:attribute> </xs:extension> </xs:complexContent> </xs:complexType> </xs:element> <xs:complexType name=“facet”> <xs:complexContent> <xs:extension base=“xs:annotated”> <xs:attribute name=“value”use=“required”/> <xs:attribute name=“fixed”type=“xs:boolean”default=“false” use=“可选”/> </xs:extension> </xs:complexContent> </xs:complexType> <xs:complexType name=“noFixedFacet”> <xs:complexContent> <xs:restriction base=“xs:facet”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> </xs:sequence> <xs:attribute name=“fixed”use=“probited”/> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> <xs:element name=“minExclusive”type=“xs:facet”id=“minExcrusive”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -minExclusive“/>(最小独占) </xs:annotation> </xs:element> <xs:element name=“minInclusive”type=“xs:facet”id=“minInclassive”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -最小非独占“/> </xs:annotation> </xs:element> <xs:element name=“maxExclusive”type=“xs:facet”id=“maxExcrusive”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -maxExclusive“/>(最大独占) </xs:annotation> </xs:element> <xs:element name=“maxInclusive”type=“xs:facet”id=“maxInclassive”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -maxInclusive“/>(最大非独占) </xs:annotation> </xs:element> <xs:complexType name=“numFacet”> <xs:complexContent> <xs:restriction base=“xs:facet”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> </xs:sequence> <xs:attribute name=“value”type=“xs:nonNegativeInteger”use=“required”/> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> <xs:element name=“totalDigits”id=“totalDigits”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -totalDigits“/> </xs:annotation> <xs:complexType> <xs:complexContent> <xs:restriction base=“xs:numFacet”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> </xs:sequence> <xs:attribute name=“value”type=“xs:positiveInteger”use=“required”/> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> </xs:element> <xs:element name=“fractionDigits”type=“xs:numFacet”id=“fractionGigits”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -小数位数“/> </xs:annotation> </xs:element> <xs:element name=“length”type=“xs:numFacet”id=“longth”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -长度“/> </xs:annotation> </xs:element> <xs:element name=“minLength”type=“xs:numFacet”id=“minLeng”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -最小长度“/> </xs:annotation> </xs:element> <xs:element name=“maxLength”type=“xs:numFacet”id=“maxLeng”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -最大长度“/> </xs:annotation> </xs:element> <xs:element name=“enumeration”type=“xs:noFixedFacet”id=“enumeration”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -枚举“/> </xs:annotation> </xs:element> <xs:element name=“whiteSpace”id=“whiteSpace”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -空白“/> </xs:annotation> <xs:complexType> <xs:complexContent> <xs:restriction base=“xs:facet”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> </xs:sequence> <xs:attribute name=“value”use=“required”> <xs:simpleType> <xs:restriction base=“xs:NMTOKEN”> <xs:enumeration value=“preserve”/> <xs:enumeration value=“replace”/> <xs:enumeration value=“collapse”/> </xs:restriction> </xs:simpleType> </xs:attribute> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> </xs:element> <xs:element name=“pattern”id=“patterm”> <xs:annotation> <xs:documentation(文档) source=“ http://www.w3.org/TR/xmlschema-2/#元素 -模式“/> </xs:annotation> <xs:complexType> <xs:complexContent> <xs:restriction base=“xs:noFixedFacet”> <xs:sequence> <xs:element ref=“xs:annotation”minOccurs=“0”/> </xs:sequence> <xs:attribute name=“value”type=“xs:string”use=“required”/> <xs:anyAttribute namespace=“##other”processContents=“lax”/> </xs:restriction> </xs:complexContent> </xs:complexType> </xs:element> </xs:schema>
<!-- XML模式的DTD:第2部分:数据类型 Id:datatypes.dtd,v 1.1 2003/08/28 13:30:52 ht实验 请注意,此DTD不是规范性的,甚至是决定性的。 --> <!-- 此DTD不能单独使用,它是有意的 仅用于纳入XMLSchema.dtd,q.v。 --> <!-- 使用可选前缀-->定义所有元素名称 <! 实体%simpleType“%p;simpleType”> <! 实体%限制“%p;限制”> <! 实体%list“%p;list”> <! 实体%union“%p;union”> <! 实体%maxExclusive“%p;maxExclussive”> <! 实体%minExclusive“%p;minExclussive”> <! 实体%maxInclusive“%p;maxIncludive”> <! 实体%minInclusive“%p;minIncludive”> <! 实体%totalDigits“%p;totalDigits”> <! 实体%fractionDigits“%p;fractionDigets”> <! 实体%length“%p;length”> <! 实体%minLength“%p;minLength> <! 实体%maxLength“%p;maxLengment”> <! ENTITY%枚举“%p;enumeration”> <! 实体%whiteSpace“%p;whiteSpace”> <! 实体%图案“%p;图案”> <!-- 每个元素的ATTLIST的自定义实体 类型。 如果您的模式占优势,请定义其中一个 架构架构中的anyAttribute=“##other” --> <! 实体%simpleTypeAttrs“”> <! 实体%限制属性“”> <! 实体%listAttrs“”> <! 实体%unionAttrs“”> <! 实体%maxExclusiveAttrs“”> <! 实体%minExclusiveAttrs“”> <! 实体%maxInclusiveAttrs“”> <! 实体%minInclusiveAttrs“”> <! 实体%totalDigitsAttrs“”> <! 实体%分数DigitsAttrs“”> <! 实体%lengthAttrs“”> <! 实体%minLengthAttrs“”> <! 实体%最大长度属性“”> <! ENTITY%枚举属性“”> <! 实体%whiteSpaceAttrs“”> <! 实体%patternAttrs“”> <!-- 定义一些实体作为属性供参考 类型--> <! 实体%URIref“CDATA”> <! 实体%XPathExpr“CDATA”> <! 实体%Q名称“NMTOKEN”> <! 实体%QNames“NMTOKENS”> <! 实体%NCName“NMTOKEN”> <! ENTITY%非负整数“NMTOKEN”> <! ENTITY%boolean“(true|false)”> <! 实体%simpleDerivationSet“CDATA”> <!-- #从derivationChoice中提取的全部或空格分隔列表 --> <!-- 请注意,下面“facet”的使用限制较少 实际上应该没有 minInclusive、minExclusive、, maxInclusive、maxExclusive、totalDigits、fractionDigits, 数据类型中的length、maxLength、minLength, 以及Inclusive和Exclusive的最小和最大变量 相互排斥。 另一方面,图案和 枚举可能重复。 --> <! 实体%minBound“(%minInclusive;|%minExclusive;)”> <! 实体%maxBound“(%maxInclusive;|%maxExclusive;)”> <! ENTITY%边界“%minBound;|%maxBound;”> <! ENTITY%numeric“%totalDigits;|%fractionDigits”> <! ENTITY%有序“%bounds;|%numeric;”> <! 未排序的实体% “”%pattern;|%enumeration;|%whiteSpace;|%length;“| %maxLength;|% 最小长度; "> <! ENTITY%方面“%ordered;|%ordered;”> <! 实体%面属性 “value CDATA#必需 id id#隐含“> <! ENTITY%fixedAttr“fixed%boolean;#IMPLIED”>(实体%固定属性) <! 实体%facetModel“(%annotation;)?”> <! 元素%simpleType; ((%annotation;)?, (%限制;|%list;|%union;)> <! ATTLIST%simpleType; 名称%NCName# 暗指的 最终%simpleDerivationSet# 暗指的 id id#隐含 %simpleTypeAttrs;> <!-- 顶层需要名称--> <! 元素%限制; ((%annotation;)?, (%限制1| ((%simpleType;)?, (%facet;)*), (%attrDecls;))> <! ATTLIST%限制; 基本%Q名称# 暗指的 id id#隐含 %限制属性;> <!-- base和simpleType子级互斥, 需要一个。 限制在simpleType和之间共享 simpleContent和complexContent(在XMLSchema.xsd中)。 限制1适用于后一种情况,此时 正在限制复杂类型,如attrDecls。 --> <! 元素%列表; ((%annotation;)?, (%simpleType;)?)> <! ATTLIST%列表; 项目类型%Q名称# 暗指的 id id#隐含 %listAttrs;> <!-- itemType和simpleType子级互斥, 需要一个 --> <! ELEMENT%联合; ((%annotation;)?, (%simpleType;)*)> <! ATTLIST%联合; id id#隐含 成员类型%QNames# 暗指的 %unionAttrs;> <!-- memberTypes或simpleType中至少有一个项 需要儿童 --> <! 元素%maxExclusive;% facetModel;> <! ATTLIST%最大独占; %面属性; %固定属性; %最大排除属性;> <! 元素%minExclusive;% facetModel;> <! ATTLIST%最小独占; %面属性; %固定属性; %最小排除属性;> <! 元素%maxInclusive;% facetModel;> <! ATTLIST%maxInclusive;属性列表%maxInclusive; %面属性; %固定属性; %maxInclusiveAttrs;> <! 元素%minInclusive;% facetModel;> <! ATTLIST%最小包含; %面属性; %固定属性; %minInclusiveAttrs;> <! 元素%totalDigits;% facetModel;> <! ATTLIST%totalDigits; %面属性; %固定属性; %总数字属性;> <! 元素%fractionDigits;% facetModel;> <! ATTLIST%分数位数; %面属性; %固定属性; %分数数字属性;> <! 元素%长度;% facetModel;> <! ATTLIST%长度; %面属性; %固定属性; %长度属性;> <! 元素%最小长度;% facetModel;> <! ATTLIST%最小长度; %面属性; %固定属性; %最小长度属性;> <! 元素%maxLength;% facetModel;> <! ATTLIST%最大长度; %面属性; %固定属性; %最大长度属性;> <!-- 这个可以重复--> <! ELEMENT%枚举;% facetModel;> <! ATTLIST%枚举; %面属性; %枚举属性;> <! 元素%空白;% facetModel;> <! ATTLIST%空格; %面属性; %固定属性; %whiteSpaceAttrs;> <!-- 这个可以重复--> <! 元素%图案;% facetModel;> <! ATTLIST%模式; %面属性; %patternAttrs;>
A类
Z轴
<simpleType name='myString'> <限制基=“字符串”> <图案值='A.*Z'/> </限制> </simpleType>
^答*Z$
.*
A类
#x41像素
<simpleType name='myString'> <限制基=“字符串”> <模式值='.*AAA.*'/> </限制> </simpleType>
|
|
|
|
|
|
|
|
|
|
|
|
|
\
^
\
[
|
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
|
|
铯
铯
|
高级代理
低代名词
高级私有用户代理
|
|
Asir S.Vedamuthu,网络方法公司 马克·戴维斯,IBM