• 原创:xml 验证 教程 schema 编辑器/设计器


    schema教程:http://www.w3school.com.cn/schema/schema_facets.asp

    schemag工具:Stylus Studio XML Enterprise Suite 2010 v11.1.1540b 多语言版(含中文)右键使用迅雷下载

    示例:

    xml:

    <?xml version="1.0"?>
    <p1:ut xmlns:p1="http://www.comsys.net.cn/schema/ut" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.comsys.net.cn/schema/ut file:///c:/Documents%20and%20Settings/Administrator/桌面/UT.xsd">
        <conf name="system">
            <property name="a1" type="string">防守对方</property>
            <property name="a2" type="string">斯蒂芬森</property>
            <property name="a9" type="string">斯蒂司法所sdf芬森</property>
            <property name="a9" type="list">斯蒂司法所sdf芬森</property>
            <property name="a10" type="list">
                <value></value>
                <value></value>
                <value></value>
                <value></value>
            </property>
        </conf>
        <conf name="udm">
            <property name="b1" type="string">12312</property>
            <property name="b2" type="string">3453</property>
            <property name="b9" type="string">sdfsdfs</property>
        </conf>
     
    </p1:ut>

    shema:

    <?xml version="1.0"?>
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.comsys.net.cn/schema/ut" xmlns="http://www.comsys.net.cn/schema/ut">
        <xsd:element name="ut">
            <xsd:complexType>
                <xsd:sequence>
                    <xsd:element name="conf" minOccurs="0" maxOccurs="unbounded">
                        <xsd:complexType >
                            <xsd:sequence>
                                <xsd:element name="property" minOccurs="0" maxOccurs="unbounded"  >
                                    <xsd:complexType mixed="true">
                                        <xsd:sequence>
                                          <xsd:element name="value" type="xsd:string" minOccurs="0" maxOccurs="unbounded"/>
                                        </xsd:sequence>
                                        <xsd:attribute name="name"/>
                                        <xsd:attribute name="type" use="optional"  default="string">
                                            <xsd:simpleType>
                                              <xsd:restriction base="xsd:string">
                                                <xsd:enumeration value="string"/>
                                                <xsd:enumeration value="list"/>
                                              </xsd:restriction>
                                            </xsd:simpleType>
                                        </xsd:attribute>
                                        
                                        
                                    </xsd:complexType>
                                </xsd:element>
                            </xsd:sequence>
                            <xsd:attribute name="name"/>
                            
                        </xsd:complexType>
                    </xsd:element>
                </xsd:sequence>
            </xsd:complexType>
        </xsd:element>
    </xsd:schema>
  • 相关阅读:
    opencvcvRound返回整数值四舍五入
    opencvcvCeil返回不小于参数的最小整数值
    opencvcvFloor返回不大于参数的最大整数值
    华为云构建云原生DevSecOps平台,保障软件供应链全流程安全可信
    云原生数据库白皮书,发布!
    云图说丨初识可信分布式身份服务
    4步教你学会使用LinuxAudit工具
    一文带你认知定时消息发布RocketMQ
    ModelBox开发体验:使用YOLOv3做口罩检测
    10种有用的Linux Bash_Completion 命令示例
  • 原文地址:https://www.cnblogs.com/jifeng/p/2620264.html
Copyright © 2020-2023  润新知