Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/three.js/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Xml XSD错误-限制标记和命名空间_Xml_Xsd - Fatal编程技术网

Xml XSD错误-限制标记和命名空间

Xml XSD错误-限制标记和命名空间,xml,xsd,Xml,Xsd,在我的.xsd文件中 <meters xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="Meter.xsd"> .... </meters> 我的下一个错误是 <xs:simpleType name="ID.Type"> <restriction base="xs:String"> <xs:en

在我的.xsd文件中

<meters xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="Meter.xsd">

....

</meters>
我的下一个错误是

<xs:simpleType name="ID.Type">
    <restriction base="xs:String">
        <xs:enumeration value="space2"/>
        <xs:enumeration value="space1"/>
    </xs:restriction>
</xs:simpleType>

我已经关闭了限制开启限制标签?语法与限制相同。

对于第二个错误,打开标记是
,而关闭标记是
。这两个标记位于不同的namcespace中,因此它们不匹配

将open标记更改为
应该可以修复它

<xs:simpleType name="ID.Type">
    <restriction base="xs:String">
        <xs:enumeration value="space2"/>
        <xs:enumeration value="space1"/>
    </xs:restriction>
</xs:simpleType>
Message: Expected end of tag 'restriction'