zoukankan      html  css  js  c++  java
  • schema的详解2

    <?xml version="1.0" encoding="UTF-8"?>
    <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.example.org/people"
        xmlns:tns="http://www.example.org/people" elementFormDefault="qualified">
    
        <element name="employees" type="tns:employeesype"></element>
    
        <complexType name="employeesype">
            <sequence minOccurs="1" maxOccurs="unbounded">
                <element name="employee">
                    <complexType>
                        <sequence>
                            <element name="name" type="string"></element>
                            <element name="age" type="tns:agetype"></element>
                            <element name="sex" type="tns:sextype"></element>
                        </sequence>
                        <attribute name="type" type="tns:type"></attribute>
                    </complexType>
                </element>
            </sequence>
        </complexType>
    
    
        <simpleType name="type">
            <restriction base="string">
                <enumeration value="董事长"></enumeration>
                <enumeration value="经理"></enumeration>
                <enumeration value="组长"></enumeration>
                <enumeration value="员工"></enumeration>
            </restriction>
        </simpleType>
        <simpleType name="agetype">
            <restriction base="int">
                <maxExclusive value="150"></maxExclusive>
                <minInclusive value="1"></minInclusive>
            </restriction>
        </simpleType>
    
        <simpleType name="sextype">
            <restriction base="string">
                <enumeration value="男"></enumeration>
                <enumeration value="女"></enumeration>
                <enumeration value="未知"></enumeration>
            </restriction>
        </simpleType>
    </schema>
    simpleType 的使用
  • 相关阅读:
    TLE: poj 1011 Sticks
    UVa 116 Unidirectional TSP
    csuoj 1215 稳定排序
    UVa 103 Stacking Boxes
    UVa 147 Dollars
    UVa 111 History Grading
    怎么在ASP.NET 2.0中使用Membership
    asp.net中如何删除cookie?
    ASP.NET中的HTTP模块和处理程序[收藏]
    NET开发中的一些小技巧
  • 原文地址:https://www.cnblogs.com/songfahzun/p/5889793.html
Copyright © 2011-2022 走看看