need to refine the checksum files a bit so programs don't have to guess.

This commit is contained in:
brent s. 2019-12-14 02:47:46 -05:00
parent 9ef5f0588e
commit ae3a64801d
2 changed files with 19 additions and 0 deletions

View File

@ -5,6 +5,7 @@


<xs:include schemaLocation="./std.xsd"/> <xs:include schemaLocation="./std.xsd"/>
<xs:include schemaLocation="./net.xsd"/> <xs:include schemaLocation="./net.xsd"/>
<xs:include schemaLocation="./unix.xsd"/>


<xs:simpleType name="t_cksum_algo"> <xs:simpleType name="t_cksum_algo">
<!-- Geared towards python. --> <!-- Geared towards python. -->
@ -42,10 +43,20 @@
<xs:simpleContent> <xs:simpleContent>
<xs:extension base="t_net_generic_resource"> <xs:extension base="t_net_generic_resource">
<xs:attribute name="hashType" use="required" type="t_cksum_algo"/> <xs:attribute name="hashType" use="required" type="t_cksum_algo"/>
<xs:attribute name="fileType" use="required" type="t_cksum_file_filetype"/>
<xs:attribute name="filePath" use="optional" type="t_unix_filepath"/>
</xs:extension> </xs:extension>
</xs:simpleContent> </xs:simpleContent>
</xs:complexType> </xs:complexType>


<xs:simpleType name="t_cksum_file_filetype">
<xs:restriction base="xs:string">
<xs:enumeration value="gnu"/>
<xs:enumeration value="bsd"/>
<xs:whiteSpace value="collapse"/>
</xs:restriction>
</xs:simpleType>

<xs:complexType name="t_cksum_hash"> <xs:complexType name="t_cksum_hash">
<xs:simpleContent> <xs:simpleContent>
<xs:extension base="t_std_nonempty"> <xs:extension base="t_std_nonempty">

View File

@ -43,6 +43,14 @@
</xs:restriction> </xs:restriction>
</xs:simpleType> </xs:simpleType>


<!-- https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_282 -->
<xs:simpleType name="t_unix_portablePosixFilename">
<xs:restriction base="xs:string">
<xs:pattern value="[A-Za-z0-9._-]+"/>
<xs:whiteSpace value="collapse"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="t_unix_posixUserGroup"> <xs:simpleType name="t_unix_posixUserGroup">
<!-- https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_437 <!-- https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_437
https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_282 https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_282