test/data/seda_1_export.xsd
author Sylvain Thénault <sylvain.thenault@logilab.fr>
Tue, 07 Nov 2017 14:40:09 +0100
changeset 2872 1e715baea780
parent 2871 20d1509fb15a
child 2987 f9d5b157e647
permissions -rw-r--r--
[profile gen] In SEDA 1.0, archival agency should occurs before transferring agency Related to #17113836

<?xml version='1.0' encoding='utf-8' standalone='no'?>
<xsd:schema
    xmlns:clm60133="urn:un:unece:uncefact:codelist:standard:6:0133:40106"
    xmlns:clmDAFFileTypeCode="urn:un:unece:uncefact:codelist:draft:DAF:fileTypeCode:2009-08-18"
    xmlns:clmIANACharacterSetCode="urn:un:unece:uncefact:codelist:standard:IANA:CharacterSetCode:2007-05-14"
    xmlns:clmIANAMIMEMediaType="urn:un:unece:uncefact:codelist:standard:IANA:MIMEMediaType:2008-11-12"
    xmlns:qdt="fr:gouv:culture:archivesdefrance:seda:v1.0:QualifiedDataType:1"
    xmlns:seda="fr:gouv:culture:archivesdefrance:seda:v2.0"
    xmlns:udt="urn:un:unece:uncefact:data:standard:UnqualifiedDataType:10"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns="fr:gouv:culture:archivesdefrance:seda:v1.0"
    attributeFormDefault="unqualified"
    elementFormDefault="qualified"
    targetNamespace="fr:gouv:culture:archivesdefrance:seda:v1.0"
    version="1.0"
    seda:warnings="">
  <xsd:element name="ArchiveTransfer">
    <xsd:annotation>
      <xsd:documentation>my profile title &amp;&amp;</xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element fixed="my profile description &amp;&amp;" name="Comment">
          <xsd:complexType>
            <xsd:simpleContent>
              <xsd:extension base="udt:TextType">
                <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
              </xsd:extension>
            </xsd:simpleContent>
          </xsd:complexType>
        </xsd:element>
        <xsd:element name="Date" type="udt:DateTimeType"/>
        <xsd:element name="TransferIdentifier">
          <xsd:complexType>
            <xsd:simpleContent>
              <xsd:extension base="qdt:ArchivesIDType">
                <xsd:attribute name="schemeID" type="xsd:token" use="optional"/>
                <xsd:attribute name="schemeName" type="xsd:string" use="optional"/>
                <xsd:attribute name="schemeAgencyName" type="xsd:string" use="optional"/>
                <xsd:attribute name="schemeVersionID" type="xsd:token" use="optional"/>
                <xsd:attribute name="schemeDataURI" type="xsd:anyURI" use="optional"/>
                <xsd:attribute name="schemeURI" type="xsd:anyURI" use="optional"/>
              </xsd:extension>
            </xsd:simpleContent>
          </xsd:complexType>
        </xsd:element>
        <xsd:element name="ArchivalAgency">
          <xsd:complexType>
            <xsd:sequence>
              <xsd:element name="Identification">
                <xsd:complexType>
                  <xsd:simpleContent>
                    <xsd:extension base="qdt:ArchivesIDType">
                      <xsd:attribute name="schemeID" type="xsd:token" use="optional"/>
                      <xsd:attribute name="schemeName" type="xsd:string" use="optional"/>
                      <xsd:attribute name="schemeAgencyName" type="xsd:string" use="optional"/>
                      <xsd:attribute name="schemeVersionID" type="xsd:token" use="optional"/>
                      <xsd:attribute name="schemeDataURI" type="xsd:anyURI" use="optional"/>
                      <xsd:attribute name="schemeURI" type="xsd:anyURI" use="optional"/>
                    </xsd:extension>
                  </xsd:simpleContent>
                </xsd:complexType>
              </xsd:element>
              <xsd:element minOccurs="0" name="Name" type="udt:TextType"/>
            </xsd:sequence>
          </xsd:complexType>
        </xsd:element>
        <xsd:element name="TransferringAgency">
          <xsd:complexType>
            <xsd:sequence>
              <xsd:element name="Identification">
                <xsd:complexType>
                  <xsd:simpleContent>
                    <xsd:extension base="qdt:ArchivesIDType">
                      <xsd:attribute name="schemeID" type="xsd:token" use="optional"/>
                      <xsd:attribute name="schemeName" type="xsd:string" use="optional"/>
                      <xsd:attribute name="schemeAgencyName" type="xsd:string" use="optional"/>
                      <xsd:attribute name="schemeVersionID" type="xsd:token" use="optional"/>
                      <xsd:attribute name="schemeDataURI" type="xsd:anyURI" use="optional"/>
                      <xsd:attribute name="schemeURI" type="xsd:anyURI" use="optional"/>
                    </xsd:extension>
                  </xsd:simpleContent>
                </xsd:complexType>
              </xsd:element>
              <xsd:element minOccurs="0" name="Name" type="udt:TextType"/>
            </xsd:sequence>
          </xsd:complexType>
        </xsd:element>
        <xsd:element maxOccurs="unbounded" name="Archive" xml:id="id%(unit-eid)s">
          <xsd:annotation>
            <xsd:documentation>archive unit title</xsd:documentation>
          </xsd:annotation>
          <xsd:complexType>
            <xsd:sequence>
              <xsd:element fixed="fra" name="DescriptionLanguage">
                <xsd:complexType>
                  <xsd:simpleContent>
                    <xsd:extension base="qdt:CodeLanguageType">
                      <xsd:attribute fixed="edition 2011" name="listVersionID" type="xsd:token" use="required"/>
                    </xsd:extension>
                  </xsd:simpleContent>
                </xsd:complexType>
              </xsd:element>
              <xsd:element name="Name">
                <xsd:complexType>
                  <xsd:simpleContent>
                    <xsd:extension base="udt:TextType">
                      <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
                    </xsd:extension>
                  </xsd:simpleContent>
                </xsd:complexType>
              </xsd:element>
              <xsd:element name="ContentDescription">
                <xsd:complexType>
                  <xsd:sequence>
                    <xsd:element minOccurs="0" name="Description">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="udt:TextType">
                            <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element fixed="file" name="DescriptionLevel">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:CodeDescriptionLevelType">
                            <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element name="Language">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:CodeLanguageType">
                            <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element minOccurs="0" name="LatestDate" type="udt:DateType"/>
                    <xsd:element minOccurs="0" name="OldestDate" type="udt:DateType"/>
                    <xsd:element minOccurs="0" name="CustodialHistory">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element minOccurs="0" name="CustodialHistoryItem" xml:id="id%(chi-eid)s">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CustodialHistoryItemType">
                                  <xsd:attribute name="when" type="udt:DateType" use="optional"/>
                                  <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                        </xsd:sequence>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element maxOccurs="unbounded" minOccurs="0" name="Keyword" xml:id="id%(kw-eid)s">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element fixed="file" name="KeywordContent">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:KeywordContentType">
                                  <xsd:attribute name="role" type="xsd:token" use="optional"/>
                                  <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element fixed="%(concept-uri)s" name="KeywordReference">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:ArchivesIDType">
                                  <xsd:attribute name="schemeID" type="xsd:token" use="optional"/>
                                  <xsd:attribute fixed="seda_description_level/None vocabulary" name="schemeName" type="xsd:string" use="required"/>
                                  <xsd:attribute name="schemeAgencyName" type="xsd:string" use="optional"/>
                                  <xsd:attribute name="schemeVersionID" type="xsd:token" use="optional"/>
                                  <xsd:attribute name="schemeDataURI" type="xsd:anyURI" use="optional"/>
                                  <xsd:attribute fixed="%(scheme-uri)s" name="schemeURI" type="xsd:anyURI" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element minOccurs="0" name="KeywordType">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeKeywordType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element minOccurs="0" name="OriginatingAgency">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element fixed="%(agent-id)s" name="Identification">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:ArchivesIDType">
                                  <xsd:attribute name="schemeID" type="xsd:token" use="optional"/>
                                  <xsd:attribute name="schemeName" type="xsd:string" use="optional"/>
                                  <xsd:attribute name="schemeAgencyName" type="xsd:string" use="optional"/>
                                  <xsd:attribute name="schemeVersionID" type="xsd:token" use="optional"/>
                                  <xsd:attribute name="schemeDataURI" type="xsd:anyURI" use="optional"/>
                                  <xsd:attribute name="schemeURI" type="xsd:anyURI" use="optional"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element fixed="%(agent-name)s" minOccurs="0" name="Name" type="udt:TextType"/>
                        </xsd:sequence>
                      </xsd:complexType>
                    </xsd:element>
                  </xsd:sequence>
                  <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                </xsd:complexType>
              </xsd:element>
              <xsd:element name="AccessRestrictionRule">
                <xsd:complexType>
                  <xsd:sequence>
                    <xsd:element name="Code">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:CodeAccessRestrictionType">
                            <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element name="StartDate" type="udt:DateType"/>
                  </xsd:sequence>
                  <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                </xsd:complexType>
              </xsd:element>
              <xsd:element minOccurs="0" name="AppraisalRule">
                <xsd:annotation>
                  <xsd:documentation>detruire le document</xsd:documentation>
                </xsd:annotation>
                <xsd:complexType>
                  <xsd:sequence>
                    <xsd:element fixed="detruire" name="Code">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:CodeAppraisalType">
                            <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element fixed="P10Y" name="Duration" type="qdt:ArchivesDurationType">
                      <xsd:annotation>
                        <xsd:documentation>C'est dans 10ans je m'en irai</xsd:documentation>
                      </xsd:annotation>
                    </xsd:element>
                    <xsd:element name="StartDate" type="udt:DateType"/>
                  </xsd:sequence>
                  <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                </xsd:complexType>
              </xsd:element>
              <xsd:element name="ArchiveObject" xml:id="id%(subunit2-eid)s">
                <xsd:annotation>
                  <xsd:documentation>archive unit title</xsd:documentation>
                </xsd:annotation>
                <xsd:complexType>
                  <xsd:sequence>
                    <xsd:element name="Name">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="udt:TextType">
                            <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element name="ContentDescription">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element fixed="file" name="DescriptionLevel">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeDescriptionLevelType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element name="Language">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeLanguageType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element name="AccessRestrictionRule">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element name="Code">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeAccessRestrictionType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element name="StartDate" type="udt:DateType"/>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element minOccurs="0" name="AppraisalRule">
                      <xsd:annotation>
                        <xsd:documentation>detruire le document</xsd:documentation>
                      </xsd:annotation>
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element fixed="detruire" name="Code">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeAppraisalType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element fixed="P10Y" name="Duration" type="qdt:ArchivesDurationType">
                            <xsd:annotation>
                              <xsd:documentation>C'est dans 10ans je m'en irai</xsd:documentation>
                            </xsd:annotation>
                          </xsd:element>
                          <xsd:element name="StartDate" type="udt:DateType"/>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                  </xsd:sequence>
                  <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                </xsd:complexType>
              </xsd:element>
              <xsd:element maxOccurs="unbounded" name="ArchiveObject" xml:id="id%(subunit1-eid)s">
                <xsd:annotation>
                  <xsd:documentation>archive unit title</xsd:documentation>
                </xsd:annotation>
                <xsd:complexType>
                  <xsd:sequence>
                    <xsd:element name="Name">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="udt:TextType">
                            <xsd:attribute name="languageID" type="xsd:language" use="optional"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element name="ContentDescription">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element fixed="file" name="DescriptionLevel">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeDescriptionLevelType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element name="Language">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeLanguageType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element name="AccessRestrictionRule">
                      <xsd:annotation>
                        <xsd:documentation>restrict</xsd:documentation>
                      </xsd:annotation>
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element fixed="AR038" name="Code">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeAccessRestrictionType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element name="StartDate" type="udt:DateType"/>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element minOccurs="0" name="AppraisalRule">
                      <xsd:complexType>
                        <xsd:sequence>
                          <xsd:element name="Code">
                            <xsd:complexType>
                              <xsd:simpleContent>
                                <xsd:extension base="qdt:CodeAppraisalType">
                                  <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                                </xsd:extension>
                              </xsd:simpleContent>
                            </xsd:complexType>
                          </xsd:element>
                          <xsd:element name="Duration" type="qdt:ArchivesDurationType"/>
                          <xsd:element name="StartDate" type="udt:DateType"/>
                        </xsd:sequence>
                        <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                      </xsd:complexType>
                    </xsd:element>
                  </xsd:sequence>
                  <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                </xsd:complexType>
              </xsd:element>
              <xsd:element maxOccurs="unbounded" minOccurs="0" name="Document" xml:id="id%(bdo-eid)s">
                <xsd:annotation>
                  <xsd:documentation>data object title</xsd:documentation>
                </xsd:annotation>
                <xsd:complexType>
                  <xsd:sequence>
                    <xsd:element name="Attachment">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:ArchivesBinaryObjectType">
                            <xsd:attribute name="format" use="required">
                              <xsd:simpleType>
                                <xsd:restriction base="xsd:token">
			                <xsd:enumeration value="fmt/123"/>
			                <xsd:enumeration value="fmt/987"/>
                                </xsd:restriction>
                              </xsd:simpleType>
                            </xsd:attribute>
                            <xsd:attribute fixed="6" name="encodingCode" type="clm60133:CharacterSetEncodingCodeContentType" use="required"/>
                            <xsd:attribute name="mimeCode" type="clmIANAMIMEMediaType:MIMEMediaTypeContentType" use="optional"/>
                            <xsd:attribute fixed="this_is_the_filename.pdf" name="filename" type="xsd:string" use="required"/>
                            <xsd:attribute name="characterSetCode" type="clmIANACharacterSetCode:CharacterSetCodeContentType" use="prohibited"/>
                            <xsd:attribute name="uri" type="xsd:anyURI" use="prohibited"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element minOccurs="0" name="Integrity">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:ArchivesHashcodeBinaryObjectType">
                            <xsd:attribute fixed="md5" name="algorithme" type="xsd:string" use="required"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                    <xsd:element fixed="CDO" name="Type">
                      <xsd:complexType>
                        <xsd:simpleContent>
                          <xsd:extension base="qdt:CodeDocumentType">
                            <xsd:attribute fixed="edition 2009" name="listVersionID" type="xsd:token" use="required"/>
                          </xsd:extension>
                        </xsd:simpleContent>
                      </xsd:complexType>
                    </xsd:element>
                  </xsd:sequence>
                  <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
                </xsd:complexType>
              </xsd:element>
            </xsd:sequence>
            <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
          </xsd:complexType>
        </xsd:element>
      </xsd:sequence>
      <xsd:attribute name="Id" type="xsd:ID" use="optional"/>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>