如何扩展对简单类型元素的限制?

Use*_*394 4 xsd

有人可以发布一个关于如何在 xml 模式中对 simpletype 元素添加枚举限制的示例吗?

WSK*_*WSK 5

  <xs:simpleType name="myElement">
    <xs:union memberTypes="previousRestrictions">
      <xs:simpleType>
        <xs:restriction base="xs:string">
          <xs:enumeration value="close" />
        </xs:restriction>
      </xs:simpleType>
    </xs:union>
  </xs:simpleType>
Run Code Online (Sandbox Code Playgroud)