用正则表达式 限定XML simpleType 定义

xiaoxiao2025-12-02  2

<xsd:simpleType name="ResTrictions"> <xsd:restriction base="xsd:string"> <xsd:pattern value="\s*0x[0-9,a-z,A-Z]{8}\s*|\s*"/> </xsd:restriction> </xsd:simpleType> View Code

匹配各种空值或者4个byte的16进制数

<test></test>

<test>0x14223344</test>

转载请注明原文地址: https://www.6miu.com/read-5040236.html

最新回复(0)