diff --git a/config/paths.php b/config/paths.php index fc9c3c60a733dd4d6c22dd4094b683af277f69bc..4a96f7c3314a49c2e22b5e7d1312c9bf02cda7ee 100644 --- a/config/paths.php +++ b/config/paths.php @@ -136,6 +136,7 @@ define('SEDA_V20_XSL', WWW_ROOT . 'seda2html' . DS . 'seda2html_v20' . DS . 'sed define('SEDA_V20_XSD', WWW_ROOT . 'xmlSchemas' . DS . 'seda_v2-0' . DS . 'seda-2.0-main.xsd'); define('SEDA_V21_XSD', WWW_ROOT . 'xmlSchemas' . DS . 'seda_v2-1' . DS . 'seda-2.1-main.xsd'); define('SEDA_ARCHIVE_V21_XSD', WWW_ROOT . 'xmlSchemas' . DS . 'seda_v2-1' . DS . 'asalae-seda-2.1-archive.xsd'); +define('SEDA_ARCHIVE_V22_XSD', WWW_ROOT . 'xmlSchemas' . DS . 'seda_v2-2' . DS . 'asalae-seda-2.2-archive.xsd'); define('EAC_CPF_XSD', WWW_ROOT . 'xmlSchemas' . DS . 'EAC-CPF' . DS . 'cpf.xsd'); define('PREMIS_V3', WWW_ROOT . 'xmlSchemas' . DS . 'premis' . DS . 'premis.xsd'); diff --git a/src/Command/ApisCommand.php b/src/Command/ApisCommand.php index 8bc8c83ee718a0c52f24622ae233945689d2d88b..cb01e200f69397995a5696991bcf827dec4b09ce 100644 --- a/src/Command/ApisCommand.php +++ b/src/Command/ApisCommand.php @@ -251,7 +251,7 @@ class ApisCommand extends Command } } while (empty($target) - || !preg_match('/^([A-Za-z0-9.-]+)\/([A-Za-z0-9-]+)$/', $target, $match) + || !preg_match('/^([A-Za-z\d.-]+)\/([A-Za-z\d-]+)$/', $target, $match) || !$this->checkExistance($match[1], $match[2]) ) { $io->out("La cible doit être indiquée sous la forme Controllers/actionEnCamelCase"); diff --git a/src/Command/ControllersCommand.php b/src/Command/ControllersCommand.php index 8f80e64d7207a5c88170f0c489634f3bde91660e..0967b2bc2dc6496a3eecad9b1cccf3eee2d6f939 100644 --- a/src/Command/ControllersCommand.php +++ b/src/Command/ControllersCommand.php @@ -253,7 +253,7 @@ class ControllersCommand extends Command } } while (empty($args) - || !preg_match('/^([A-Za-z0-9.-]+)\/([A-Za-z0-9-]+)$/', $args, $match) + || !preg_match('/^([A-Za-z\d.-]+)\/([A-Za-z\d-]+)$/', $args, $match) || !$this->checkExistance($match[1], $match[2]) ) { $this->out("La cible doit être indiquée sous la forme Controllers/actionEnCamelCase"); @@ -344,7 +344,7 @@ class ControllersCommand extends Command public function get($target = null) { while (empty($target) - || !preg_match('/^([A-Za-z0-9.-]+)\/([A-Za-z0-9-]+)$/', $target, $match) + || !preg_match('/^([A-Za-z\d.-]+)\/([A-Za-z\d-]+)$/', $target, $match) || !$this->checkExistance($match[1], $match[2]) ) { $this->out("La cible doit être indiquée sous la forme Controllers/actionEnCamelCase"); diff --git a/src/Command/JobCommand.php b/src/Command/JobCommand.php index 45fbbb92856605e99edaadffb609df9a810fcc26..ce8aa96fe9c8f63951b4665a026663a1be938e34 100644 --- a/src/Command/JobCommand.php +++ b/src/Command/JobCommand.php @@ -87,7 +87,7 @@ class JobCommand extends Command $value = false; } elseif ($value === 'null') { $value = null; - } elseif (preg_match('/^[\d]+\.[\d]*$/', $value)) { + } elseif (preg_match('/^\d+\.\d*$/', $value)) { $value = (float)$value; } elseif (is_numeric($value)) { $value = (int)$value; diff --git a/src/Command/PromptOptionsTrait.php b/src/Command/PromptOptionsTrait.php index 01b53f693033543b104567c5bbbac95f5a4e6604..e9bb66d2d9497af3051372c2182fb3b2c11943aa 100644 --- a/src/Command/PromptOptionsTrait.php +++ b/src/Command/PromptOptionsTrait.php @@ -49,9 +49,9 @@ trait PromptOptionsTrait } $argv = $_SERVER['argv']; foreach ($argv as $arg) { - if (preg_match('/^--([\w]+)$/', $arg, $match)) { + if (preg_match('/^--(\w+)$/', $arg, $match)) { unset($longs[$match[1]], $shorts[$match[1]]); - } elseif (preg_match('/^-([\w])$/', $arg, $match)) { + } elseif (preg_match('/^-(\w)$/', $arg, $match)) { $key = array_search($match[1], $shorts); unset($longs[$key], $shorts[$key]); } diff --git a/src/Command/TraductionCommand.php b/src/Command/TraductionCommand.php index 7d950f81bbd3a794908dec73d558a05296fb34cf..dac7d4a8379089a755c62ec3ede64096a8f5b700 100644 --- a/src/Command/TraductionCommand.php +++ b/src/Command/TraductionCommand.php @@ -165,7 +165,7 @@ class TraductionCommand extends Command while (!feof($handle)) { $buffer = fgets($handle); - if ($begin && !preg_match('/(^#: .*[\d]+$|^msg(ctxt|id) ".+")/', $buffer)) { + if ($begin && !preg_match('/(^#: .*\d+$|^msg(ctxt|id) ".+")/', $buffer)) { if (strpos($buffer, '"PO-Revision-Date: ') === 0) { $parsed['__header__'] .= '"PO-Revision-Date: ' . date('Y-m-d H:i') . '+0000\n"'.PHP_EOL; } elseif (empty(trim($buffer))) { @@ -188,7 +188,7 @@ class TraductionCommand extends Command $id = $match[1]; $parsed[$context][$id]['id'] = $id; $parsed[$context][$id]['comments'] = $comments; - } elseif (preg_match('/msg(id_plural|str|str\[[\d]+]) "(.+)"/', $buffer, $match)) { + } elseif (preg_match('/msg(id_plural|str|str\[\d+]) "(.+)"/', $buffer, $match)) { $parsed[$context][$id][$match[1]] = $match[2]; } } @@ -326,7 +326,7 @@ class TraductionCommand extends Command exec(sprintf('printf "%%s" "%s" | xclip -sel clip >/dev/null 2>&1', trim(addcslashes($id, '`"'), "'"))); $this->ioShell->out(sprintf("<info>%s / %s</info>", $i+1, $c)); $comment = !empty($po[$context][$id]['comments']) ? ' ('.current($po[$context][$id]['comments']).')' : ''; - if (preg_match('/^#: ([^:]+):([\d]+)/', trim($comment, '() '), $matches)) { + if (preg_match('/^#: ([^:]+):(\d+)/', trim($comment, '() '), $matches)) { if (is_readable($filename = APP . $matches[1])) { $extracted = ContextDebugger::getContext($filename, (int)$matches[2], 3); $extracted = str_replace('<b>', '</comment><error>', $extracted); @@ -475,7 +475,7 @@ class TraductionCommand extends Command private function completeStr(string $domain, string $context, string $id, string $comment): string { exec(sprintf('printf "%%s" "%s" | xclip -sel clip >/dev/null 2>&1', trim(addcslashes($id, '`"'), "'"))); - if (preg_match('/^#: ([^:]+):([\d]+)/', $comment, $matches)) { + if (preg_match('/^#: ([^:]+):(\d+)/', $comment, $matches)) { if (is_readable($filename = APP . $matches[1])) { $extracted = ContextDebugger::getContext($filename, (int)$matches[2], 3); $extracted = str_replace('<b>', '</comment><error>', $extracted); diff --git a/src/Controller/Component/ConditionComponent.php b/src/Controller/Component/ConditionComponent.php index 69e3540d8c2f72e010fed6d41ae3af3eaa245ac6..9f35d856b2a2d1aefe5f99b6d8f1df1916ba6fa9 100644 --- a/src/Controller/Component/ConditionComponent.php +++ b/src/Controller/Component/ConditionComponent.php @@ -282,7 +282,7 @@ class ConditionComponent extends Component } $favoritesIds = []; foreach (array_keys($cookies) as $cookieName) { - if (preg_match("/^table-favorite-$table-$action-table-([\d]+)$/", $cookieName, $match)) { + if (preg_match("/^table-favorite-$table-$action-table-(\d+)$/", $cookieName, $match)) { $favoritesIds[] = $match[1]; } } diff --git a/src/Controller/Component/IndexComponent.php b/src/Controller/Component/IndexComponent.php index c19c6252bc7788a277c51b3311b0fa7f1be16543..b6f5d744e148c52f04742bd979e62e49ac56fab2 100644 --- a/src/Controller/Component/IndexComponent.php +++ b/src/Controller/Component/IndexComponent.php @@ -5,7 +5,7 @@ namespace AsalaeCore\Controller\Component; -use Asalae\View\Helper\TranslateHelper; +use AsalaeCore\View\Helper\TranslateHelper; use Cake\Controller\Component; use Cake\Core\Configure; use Cake\Http\Exception\BadRequestException; diff --git a/src/Controller/Component/SealComponent.php b/src/Controller/Component/SealComponent.php new file mode 100644 index 0000000000000000000000000000000000000000..1defdf53babf2da53284662fbebaa54531644180 --- /dev/null +++ b/src/Controller/Component/SealComponent.php @@ -0,0 +1,223 @@ +<?php +/** + * AsalaeCore\Controller\Component\SealComponent + */ + +namespace AsalaeCore\Controller\Component; + +use AsalaeCore\Model\Behavior\SealBehavior; +use AsalaeCore\Model\Table\AgreementsTable; +use AsalaeCore\Model\Table\ArchivingSystemsTable; +use AsalaeCore\Model\Table\CountersTable; +use AsalaeCore\Model\Table\EaccpfsTable; +use AsalaeCore\Model\Table\FileuploadsTable; +use AsalaeCore\Model\Table\KeywordListsTable; +use AsalaeCore\Model\Table\KeywordsTable; +use AsalaeCore\Model\Table\LdapsTable; +use AsalaeCore\Model\Table\OrgEntitiesTable; +use AsalaeCore\Model\Table\ProfilesTable; +use AsalaeCore\Model\Table\RolesTable; +use AsalaeCore\Model\Table\SequencesTable; +use AsalaeCore\Model\Table\ServiceLevelsTable; +use AsalaeCore\Model\Table\UsersTable; +use Cake\Controller\Component; +use Cake\Controller\ComponentRegistry; +use Cake\Controller\Controller; +use Cake\Datasource\EntityInterface; +use Cake\ORM\Table; +use Cake\ORM\TableRegistry; +use Cake\Utility\Hash; + +/** + * Logiques d'accès à certaines fonctions + * (hierarchical_view, super archivistes, service d'archives) + * + * @category Controller + * + * @author Libriciel SCOP <contact@libriciel.coop> + * @copyright (c) 2022 Libriciel + * @license https://www.gnu.org/licenses/agpl-3.0.txt + * @property AgreementsTable Agreements + * @property ArchivingSystemsTable ArchivingSystems + * @property CountersTable Counters + * @property EaccpfsTable Eaccpfs + * @property FileuploadsTable Fileuploads + * @property KeywordListsTable KeywordLists + * @property KeywordsTable Keywords + * @property LdapsTable Ldaps + * @property OrgEntitiesTable OrgEntities + * @property ProfilesTable Profiles + * @property RolesTable Roles + * @property SequencesTable Sequences + * @property ServiceLevelsTable ServiceLevels + * @property UsersTable Users + */ +class SealComponent extends Component +{ + const COND_ARCHIVAL_AGENCY = 'archivalAgency'; + const COND_ARCHIVAL_AGENCY_CHILDS = 'archivalAgencyChilds'; + const COND_HIERARCHICAL_VIEW = 'hierarchicalView'; + const COND_ORG_ENTITY = 'orgEntity'; + const COND_ORG_ENTITY_CHILDS = 'orgEntityChilds'; + + /** + * Default config + * + * These are merged with user-provided config when the component is used. + * + * @var array<string, bool, array> + */ + protected $_defaultConfig = [ + 'user' => [], + 'userId' => null, + 'orgEntity' => [], + 'orgEntityId' => null, + 'archivalAgency' => [], + 'archivalAgencyId' => null, + 'superArchivist' => false, + 'adminTech' => false, + 'condition' => null, + ]; + + /** + * Constructor + * + * @param \Cake\Controller\ComponentRegistry $registry A component registry + * this component can use to lazy load its components. + * @param array<string, mixed> $config Array of configuration settings. + */ + public function __construct(ComponentRegistry $registry, array $config = []) + { + foreach ($config as $key => $value) { + if ($value instanceof EntityInterface) { + $config[$key] = $value->toArray(); + } + } + parent::__construct($registry, $config); + } + + /** + * Permet d'utiliser ce Component en dehors des controlleurs pour tester + * les conditions lors d'un debug par exemple + * @param int $userId + * @param bool $isAdminTech + * @return static + */ + public static function createForUser(int $userId, bool $isAdminTech = false): self + { + $registry = new ComponentRegistry(new Controller()); + $user = TableRegistry::getTableLocator()->get('Users')->find() + ->where(['Users.id' => $userId]) + ->contain( + [ + 'OrgEntities' => [ + 'ArchivalAgencies' => ['Configurations'], + 'TypeEntities', + ], + 'Ldaps', + 'Roles', + ] + ) + ->firstOrFail(); + return new self( + $registry, + [ + 'user' => $user, + 'userId' => Hash::get($user, 'id'), + 'orgEntity' => Hash::get($user, 'org_entity', []), + 'orgEntityId' => Hash::get($user, 'org_entity_id'), + 'archivalAgency' => Hash::get($user, 'org_entity.archival_agency', []), + 'archivalAgencyId' => Hash::get($user, 'org_entity.archival_agency.id', []), + 'superArchivist' => Hash::get($user, 'role.code') === 'SAA', + 'adminTech' => $isAdminTech, + ] + ); + } + + /** + * Défini le type de condition "archivalAgency" + * Applique une condition type : + * Model.archival_agency_id = LoggedUser.archival_agency_id + * @return $this + * @link SealBehavior::appendConditionsArchivalAgency() + */ + public function archivalAgency() + { + $this->setConfig('condition', self::COND_ARCHIVAL_AGENCY); + return $this; + } + + /** + * Défini le type de condition "archivalAgencyChilds" + * Applique une condition type : + * Model.lft >= ArchivalAgency.lft AND Model.rght >= ArchivalAgency.rght + * @return $this + * @link SealBehavior::appendConditionsArchivalAgencyChilds() + */ + public function archivalAgencyChilds() + { + $this->setConfig('condition', self::COND_ARCHIVAL_AGENCY_CHILDS); + return $this; + } + + /** + * Défini le type de condition "hierarchicalView" + * Se distingue de "archivalAgencyChilds" par la nécéssité que le role + * utilisateur doit avoir l'option "hierarchical_view" + * De plus, selon le type de l'entité de l'utilisateur, le lft/rght est soit + * sur le service d'archives, soit sur l'entité + * + * Applique une condition type : + * Model.lft >= ArchivalAgency.lft AND Model.rght >= ArchivalAgency.rght + * + * @return $this + * @link SealBehavior::appendConditionsHierarchicalView() + */ + public function hierarchicalView() + { + $this->setConfig('condition', self::COND_HIERARCHICAL_VIEW); + return $this; + } + + /** + * Défini le type de condition "archivalAgency" + * Applique une condition type : + * Model.archival_agency_id = LoggedUser.archival_agency_id + * @return $this + * @link SealBehavior::appendConditionsOrgEntity() + */ + public function orgEntity() + { + $this->setConfig('condition', self::COND_ORG_ENTITY); + return $this; + } + + /** + * Défini le type de condition "archivalAgency" + * Applique une condition type : + * Model.archival_agency_id = LoggedUser.archival_agency_id + * @return $this + * @link SealBehavior::appendConditionsOrgEntityChilds() + */ + public function orgEntityChilds() + { + $this->setConfig('condition', self::COND_ORG_ENTITY_CHILDS); + return $this; + } + + /** + * Donne le model avec SealBehavior configuré + * @param string $name + * @return Table|null + */ + public function __get($name) + { + $this->setConfig('model', $name); + $model = $this->getController()->fetchTable($name); + if ($model->hasBehavior('Seal')) { + $model->removeBehavior('Seal'); + } + $model->addBehavior('Seal', $this->getConfig()); + return $model; + } +} diff --git a/src/Datasource/Paginator.php b/src/Datasource/Paginator.php index 6d32d79da871100624808002b73a909f3bc45de5..86037690e61660eeba8606d7332717fff879dabc 100644 --- a/src/Datasource/Paginator.php +++ b/src/Datasource/Paginator.php @@ -6,7 +6,6 @@ namespace AsalaeCore\Datasource; use AsalaeCore\Http\AppServerRequest; -use Cake\Core\Exception\CakeException; use Cake\Database\Expression\OrderByExpression; use Cake\Datasource\Exception\PageOutOfBoundsException; use Cake\Datasource\Paging\NumericPaginator; diff --git a/src/Form/GenericMessageFormTrait.php b/src/Form/GenericMessageFormTrait.php index f8469211715bb82e5efbaf8be6285fce0eb5980b..4f4e395e6ae8970c9975f96e8b2a076fad59bcc1 100644 --- a/src/Form/GenericMessageFormTrait.php +++ b/src/Form/GenericMessageFormTrait.php @@ -441,7 +441,7 @@ trait GenericMessageFormTrait ) { $count = 0; foreach (array_keys($context['data']) as $dataField) { - if (preg_match("/^{$field}_#[\d]+$/", $dataField)) { + if (preg_match("/^{$field}_#\d+$/", $dataField)) { $count++; } } @@ -915,7 +915,7 @@ trait GenericMessageFormTrait $formatedErrors = []; foreach ($validator->errors as $error) { if (preg_match( - "/^Error (\d+)[^\d]*(\d+),.*Element '$namespaces(\w+)', attribute '(\w+)': (.*)$/", + "/^Error (\d+)\D*(\d+),.*Element '$namespaces(\w+)', attribute '(\w+)': (.*)$/", $error, $matches ) @@ -931,7 +931,7 @@ trait GenericMessageFormTrait $message ); } elseif (preg_match( - "/^Error (\d+)[^\d]*(\d+),.*Element '$namespaces(\w+(?:', attribute '\w+)?)': (.*)$/", + "/^Error (\d+)\D*(\d+),.*Element '$namespaces(\w+(?:', attribute '\w+)?)': (.*)$/", $error, $matches ) diff --git a/src/Form/MessageSchema/SchemaTrait.php b/src/Form/MessageSchema/SchemaTrait.php index 826edd54c3484b6e09540e4578e458fd14e1e00b..69c9bb4bbd5b449856811fa5e2e1b694462d4dc7 100644 --- a/src/Form/MessageSchema/SchemaTrait.php +++ b/src/Form/MessageSchema/SchemaTrait.php @@ -126,9 +126,9 @@ trait SchemaTrait IntlDateFormatter::NONE ); $this->localFormat = preg_replace( - '/[^\w]/', + '/\W/', '', - preg_replace('/([\w])[\w]+/', '$1', strtolower($formatter->getPattern())) + preg_replace('/(\w)\w+/', '$1', strtolower($formatter->getPattern())) ); } return $this->localFormat; diff --git a/src/Http/Response.php b/src/Http/Response.php index bb82b45e4286cd2339a7d8a6637e0585b7d6d428..420d42d12cdab6da9b0c483a82635d5695e1a583 100644 --- a/src/Http/Response.php +++ b/src/Http/Response.php @@ -48,8 +48,8 @@ class Response extends CakeResponse /** * Empeche de modifier les headers d'une réponse envoyée partiellement, les * entêtes ont déja été envoyés... - * @param string $name Case-insensitive header field name. - * @param string|string[] $value Header value(s). + * @param string $name Case-insensitive header field name. + * @param string|string[] $value Header value(s). * @return static * @throws InvalidArgumentException for invalid header names or values. */ diff --git a/src/MinkSuite/ChromeDriver.php b/src/MinkSuite/ChromeDriver.php index a0f065cb35e8ac2ffdc5bb37a6de1be5d14e083a..5b1b2e9bbc6547f65a2ed0888878219d089717e6 100644 --- a/src/MinkSuite/ChromeDriver.php +++ b/src/MinkSuite/ChromeDriver.php @@ -48,10 +48,10 @@ class ChromeDriver extends DMoreChromeDriver /** * ChromeDriver constructor. * - * @param string $api_url - * @param HttpClient $http_client - * @param mixed $base_url - * @param array $options + * @param string $api_url + * @param HttpClient|null $http_client + * @param mixed $base_url + * @param array $options * @noinspection PhpMissingParentConstructorInspection override */ public function __construct( diff --git a/src/Model/Behavior/SealBehavior.php b/src/Model/Behavior/SealBehavior.php new file mode 100644 index 0000000000000000000000000000000000000000..246f1a73acb1e13757d6ce2fbf8914221e528fc1 --- /dev/null +++ b/src/Model/Behavior/SealBehavior.php @@ -0,0 +1,899 @@ +<?php +/** + * AsalaeCore\Model\Behavior\SealBehavior + */ + +namespace AsalaeCore\Model\Behavior; + +use AsalaeCore\Controller\Component\SealComponent; +use AsalaeCore\Exception\GenericException; +use Cake\Datasource\EntityInterface; +use Cake\Http\Exception\ForbiddenException; +use Cake\ORM\Behavior; +use Cake\ORM\Query; +use Cake\ORM\Table; + +/** + * Ajoute les conditions d'étanchéité + * + * @category Entity + * + * @author Libriciel SCOP <contact@libriciel.coop> + * @copyright (c) 2022, Libriciel + * @license https://www.gnu.org/licenses/agpl-3.0.txt + */ +class SealBehavior extends Behavior +{ + /** + * Default config + * + * These are merged with user-provided config when the component is used. + * + * @var array<string, mixed> + */ + protected $_defaultConfig = [ + 'user' => [], + 'userId' => null, + 'orgEntity' => [], + 'orgEntityId' => null, + 'archivalAgency' => [], + 'archivalAgencyId' => null, + 'superArchivist' => false, + 'adminTech' => false, + 'condition' => false, + ]; + + + /** + * Constructor + * + * Merges config with the default and store in the config property + * + * @param \Cake\ORM\Table $table The table this behavior is attached to. + * @param array<string, mixed> $config The config for this behavior. + */ + public function __construct(Table $table, array $config = []) + { + foreach ($config as $key => $value) { + if ($value instanceof EntityInterface) { + $config[$key] = $value->toArray(); + } + } + parent::__construct($table, $config); + } + + /** + * Ajoute les conditions d'étanchéité + * @param Query $query + * @param array $options + * @return Query + */ + public function findSeal(Query $query, array $options): Query + { + $modelName = $this->getConfig('model'); + $fn = "conditionsFor$modelName"; + if (!method_exists($this, $fn)) { + throw new GenericException($fn . ' does not exists in SealBehavior'); + } + if ($this->getConfig('adminTech')) { + return $query; + } + if (!$this->getConfig('userId')) { + throw new GenericException('A user must be logged in to request a seal'); + } + if (!$this->getConfig('archivalAgencyId')) { + throw new ForbiddenException(__("L'utilisateur doit être lié à un service d'archives")); + } + + return $this->$fn($query, $options); + } + + /** + * equivalent du Table->exists() + * @param array $conditions + * @return bool + */ + public function sealExists(array $conditions): bool + { + return (bool)count( + $this->table()->find('seal') + ->select(['existing' => 1]) + ->where($conditions) + ->limit(1) + ->disableHydration() + ->toArray() + ); + } + + /** + * Ajoute les conditions d'étanchéité sur un find('list') + * @param Query $query + * @param array $options + * @return Query + */ + public function findSealList(Query $query, array $options): Query + { + $modelName = $this->getConfig('model'); + $fn = "conditionsFor$modelName"; + if (!method_exists($this, $fn)) { + throw new GenericException($fn . ' does not exists in SealBehavior'); + } + if ($this->getConfig('adminTech')) { + return $this->table()->findList($query, $options); + } + if (!$this->getConfig('userId')) { + throw new GenericException('A user must be logged in to request a seal'); + } + if (!$this->getConfig('archivalAgencyId')) { + throw new ForbiddenException(__("L'utilisateur doit être lié à un service d'archives")); + } + $query = $this->table()->findList($query, $options); + + return $this->$fn($query, $options); + } + + /** + * Ajoute les conditions d'étanchéité sur un find('threaded') + * @param Query $query + * @param array $options + * @return Query + */ + public function findSealThreaded(Query $query, array $options): Query + { + $modelName = $this->getConfig('model'); + $fn = "conditionsFor$modelName"; + if (!method_exists($this, $fn)) { + throw new GenericException($fn . ' does not exists in SealBehavior'); + } + if ($this->getConfig('adminTech')) { + return $this->table()->findThreaded($query, $options); + } + if (!$this->getConfig('userId')) { + throw new GenericException('A user must be logged in to request a seal'); + } + if (!$this->getConfig('archivalAgencyId')) { + throw new ForbiddenException(__("L'utilisateur doit être lié à un service d'archives")); + } + $query = $this->table()->findThreaded($query, $options); + + return $this->$fn($query, $options); + } + + /** + * Conditions pour Agreements + * @param Query $query + * @return Query + */ + public function conditionsForAgreements(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour ArchiveBinaries + * @param Query $query + * @return Query + */ + public function conditionsForArchiveBinaries(Query $query): Query + { + $query + ->innerJoinWith('ArchiveUnits') + ->innerJoinWith('ArchiveUnits.Archives') + ->innerJoinWith('ArchiveUnits.Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveBinariesArchiveUnits + * @param Query $query + * @return Query + */ + public function conditionsForArchiveBinariesArchiveUnits(Query $query): Query + { + $query + ->innerJoinWith('ArchiveUnits') + ->innerJoinWith('ArchiveUnits.Archives') + ->innerJoinWith('ArchiveUnits.Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveFiles + * @param Query $query + * @return Query + */ + public function conditionsForArchiveFiles(Query $query): Query + { + $query + ->innerJoinWith('Archives') + ->innerJoinWith('Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveKeywords + * @param Query $query + * @return Query + */ + public function conditionsForArchiveKeywords(Query $query): Query + { + $query + ->innerJoinWith('ArchiveUnits') + ->innerJoinWith('ArchiveUnits.Archives') + ->innerJoinWith('ArchiveUnits.Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveUnits + * @param Query $query + * @return Query + */ + public function conditionsForArchiveUnits(Query $query): Query + { + $query + ->innerJoinWith('Archives') + ->innerJoinWith('Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveUnitsBatchTreatments + * @param Query $query + * @return Query + */ + public function conditionsForArchiveUnitsBatchTreatments(Query $query): Query + { + $query + ->innerJoinWith('BatchTreatments') + ->innerJoinWith('BatchTreatments.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveUnitsDestructionRequests + * @param Query $query + * @return Query + */ + public function conditionsForArchiveUnitsDestructionRequests(Query $query): Query + { + $query + ->innerJoinWith('ArchiveUnits') + ->innerJoinWith('ArchiveUnits.Archives') + ->innerJoinWith('ArchiveUnits.Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveUnitsOutgoingTransferRequests + * @param Query $query + * @return Query + */ + public function conditionsForArchiveUnitsOutgoingTransferRequests(Query $query): Query + { + $query + ->innerJoinWith('ArchiveUnits') + ->innerJoinWith('ArchiveUnits.Archives') + ->innerJoinWith('ArchiveUnits.Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ArchiveUnitsRestitutionRequests + * @param Query $query + * @return Query + */ + public function conditionsForArchiveUnitsRestitutionRequests(Query $query): Query + { + $query + ->innerJoinWith('ArchiveUnits') + ->innerJoinWith('ArchiveUnits.Archives') + ->innerJoinWith('ArchiveUnits.Archives.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour Archives + * @param Query $query + * @return Query + */ + public function conditionsForArchives(Query $query): Query + { + $query->innerJoinWith('ArchivalAgencies'); + if ($this->getConfig('condition') === SealComponent::COND_ARCHIVAL_AGENCY) { + return $this->appendConditionsArchivalAgency($query, ['ArchivalAgencies']); + } + $query + ->innerJoinWith('TransferringAgencies') + ->innerJoinWith('OriginatingAgencies'); + return $this->appendConditions( + $query, + ['ArchivalAgencies', 'TransferringAgencies', 'OriginatingAgencies'] + ); + } + + /** + * Conditions pour ArchivingSystems + * @param Query $query + * @return Query + */ + public function conditionsForArchivingSystems(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour BatchTreatments + * @param Query $query + * @return Query + */ + public function conditionsForBatchTreatments(Query $query): Query + { + $query + ->innerJoinWith('ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour BeanstalkJobs + * @param Query $query + * @return Query + */ + public function conditionsForBeanstalkJobs(Query $query): Query + { + $query + ->innerJoinWith('Users') + ->innerJoinWith('Users.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Counters + * @param Query $query + * @return Query + */ + public function conditionsForCounters(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Deliveries + * @param Query $query + * @return Query + */ + public function conditionsForDeliveries(Query $query): Query + { + $query + ->innerJoinWith('DeliveryRequests') + ->innerJoinWith('DeliveryRequests.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour DeliveryRequests + * @param Query $query + * @return Query + */ + public function conditionsForDeliveryRequests(Query $query): Query + { + $baseModel = $this->getConfig('condition') === SealComponent::COND_ARCHIVAL_AGENCY + ? 'ArchivalAgencies' + : 'Requesters'; + $query->innerJoinWith($baseModel); + return $this->appendConditions($query, [$baseModel]); + } + + /** + * Conditions pour DestructionNotifications + * @param Query $query + * @return Query + */ + public function conditionsForDestructionNotifications(Query $query): Query + { + $query + ->innerJoinWith('DestructionRequests') + ->innerJoinWith('DestructionRequests.ArchivalAgencies'); + $baseModels = ['ArchivalAgencies']; + if ($this->getConfig('condition') === SealComponent::COND_ORG_ENTITY) { + $baseModels[] = 'OriginatingAgencies'; + $query + ->innerJoinWith('DestructionRequests.OriginatingAgencies'); + } + return $this->appendConditions($query, $baseModels); + } + + /** + * Conditions pour DestructionRequests + * @param Query $query + * @return Query + */ + public function conditionsForDestructionRequests(Query $query): Query + { + $query + ->innerJoinWith('ArchivalAgencies'); + $baseModels = ['ArchivalAgencies']; + if ($this->getConfig('condition') === SealComponent::COND_ORG_ENTITY) { + $baseModels[] = 'OriginatingAgencies'; + $query + ->innerJoinWith('OriginatingAgencies'); + } + return $this->appendConditions($query, $baseModels); + } + + /** + * Conditions pour Eaccpfs + * @param Query $query + * @return Query + */ + public function conditionsForEaccpfs(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Fileuploads + * @param Query $query + * @return Query + */ + public function conditionsForFileuploads(Query $query): Query + { + $query + ->innerJoinWith('Users') + ->innerJoinWith('Users.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour KeywordLists + * @param Query $query + * @return Query + */ + public function conditionsForKeywordLists(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Keywords + * @param Query $query + * @return Query + */ + public function conditionsForKeywords(Query $query): Query + { + $query + ->innerJoinWith('KeywordLists') + ->innerJoinWith('KeywordLists.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Ldaps + * @param Query $query + * @return Query + */ + public function conditionsForLdaps(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Ldaps + * @param Query $query + * @return Query + */ + public function conditionsForOrgEntities(Query $query): Query + { + switch ($this->getConfig('condition')) { + case SealComponent::COND_ARCHIVAL_AGENCY: + case SealComponent::COND_HIERARCHICAL_VIEW: + $baseModels = ['ArchivalAgencies']; + $query->contain('ArchivalAgencies'); + break; + case SealComponent::COND_ARCHIVAL_AGENCY_CHILDS: + case SealComponent::COND_ORG_ENTITY: + case SealComponent::COND_ORG_ENTITY_CHILDS: + $baseModels = ['OrgEntities']; + break; + default: + throw new GenericException('condition not found'); + } + return $this->appendConditions($query, $baseModels); + } + + /** + * Conditions pour OrgEntitiesTimestampers + * @param Query $query + * @return Query + */ + public function conditionsForOrgEntitiesTimestampers(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour OutgoingTransferRequests + * @param Query $query + * @return Query + */ + public function conditionsForOutgoingTransferRequests(Query $query): Query + { + $query + ->innerJoinWith('ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour OutgoingTransfers + * @param Query $query + * @return Query + */ + public function conditionsForOutgoingTransfers(Query $query): Query + { + $query + ->innerJoinWith('OutgoingTransferRequests') + ->innerJoinWith('OutgoingTransferRequests.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour Profiles + * @param Query $query + * @return Query + */ + public function conditionsForProfiles(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour RestitutionRequests + * @param Query $query + * @return Query + */ + public function conditionsForRestitutionRequests(Query $query): Query + { + $query + ->innerJoinWith('ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour Restitutions + * @param Query $query + * @return Query + */ + public function conditionsForRestitutions(Query $query): Query + { + $query + ->innerJoinWith('RestitutionRequests') + ->innerJoinWith('RestitutionRequests.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour Roles + * @param Query $query + * @return Query + */ + public function conditionsForRoles(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour SecureDataSpaces + * @param Query $query + * @return Query + */ + public function conditionsForSecureDataSpaces(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Sequences + * @param Query $query + * @return Query + */ + public function conditionsForSequences(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour ServiceLevels + * @param Query $query + * @return Query + */ + public function conditionsForServiceLevels(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour TechnicalArchives + * @param Query $query + * @return Query + */ + public function conditionsForTechnicalArchives(Query $query): Query + { + $query + ->innerJoinWith('ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour TransferAttachments + * @param Query $query + * @return Query + */ + public function conditionsForTransferAttachments(Query $query): Query + { + $query + ->innerJoinWith('Transfers') + ->innerJoinWith('Transfers.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour TransferErrors + * @param Query $query + * @return Query + */ + public function conditionsForTransferErrors(Query $query): Query + { + $query + ->innerJoinWith('Transfers') + ->innerJoinWith('Transfers.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Transfers + * @param Query $query + * @return Query + */ + public function conditionsForTransfers(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour Users + * @param Query $query + * @return Query + */ + public function conditionsForUsers(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities') + ->innerJoinWith('OrgEntities.ArchivalAgencies'); + return $this->appendConditions($query); + } + + /** + * Conditions pour ValidationChains + * @param Query $query + * @return Query + */ + public function conditionsForValidationChains(Query $query): Query + { + $query + ->innerJoinWith('OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour ValidationProcesses + * @param Query $query + * @return Query + */ + public function conditionsForValidationProcesses(Query $query): Query + { + $query + ->innerJoinWith('ValidationChains') + ->innerJoinWith('ValidationChains.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Conditions pour ValidationStages + * @param Query $query + * @return Query + */ + public function conditionsForValidationStages(Query $query): Query + { + $query + ->innerJoinWith('ValidationChains') + ->innerJoinWith('ValidationChains.OrgEntities'); + return $this->appendConditions($query, ['OrgEntities']); + } + + /** + * Ajoute les conditions selon la config condition + * @param Query $query + * @param array $baseModels + * @return Query + */ + private function appendConditions(Query $query, array $baseModels = ['ArchivalAgencies']): Query + { + switch ($this->getConfig('condition')) { + case SealComponent::COND_ARCHIVAL_AGENCY: + return $this->appendConditionsArchivalAgency($query, $baseModels); + case SealComponent::COND_ARCHIVAL_AGENCY_CHILDS: + return $this->appendConditionsArchivalAgencyChilds($query, $baseModels); + case SealComponent::COND_HIERARCHICAL_VIEW: + return $this->appendConditionsHierarchicalView($query, $baseModels); + case SealComponent::COND_ORG_ENTITY: + return $this->appendConditionsOrgEntity($query, $baseModels); + case SealComponent::COND_ORG_ENTITY_CHILDS: + return $this->appendConditionsOrgEntityChilds($query, $baseModels); + } + throw new GenericException('condition not found'); + } + + /** + * Applique une condition type : + * Model.archival_agency_id = LoggedUser.archival_agency_id + * @param Query $query + * @param array $baseModels + * @return Query + */ + private function appendConditionsArchivalAgency(Query $query, array $baseModels): Query + { + $conditions = []; + foreach ($baseModels as $baseModel) { + $conditions["$baseModel.id"] = $this->getConfig('archivalAgencyId'); + } + if (count($conditions) > 1) { + $conditions = ['OR' => $conditions]; + } + return $query->where($conditions); + } + + /** + * Applique une condition type : + * Model.lft >= ArchivalAgency.lft AND Model.rght >= ArchivalAgency.rght + * @param Query $query + * @param array $baseModels + * @return Query + */ + private function appendConditionsArchivalAgencyChilds(Query $query, array $baseModels): Query + { + $lft = $this->getConfig('archivalAgency.lft'); + $rght = $this->getConfig('archivalAgency.rght'); + if (!$lft || !$rght) { + throw new GenericException('archivalAgency is required'); + } + $conditions = []; + foreach ($baseModels as $baseModel) { + $conditions[] = [ + "$baseModel.lft >=" => $lft, + "$baseModel.rght <=" => $rght, + ]; + } + if (count($conditions) > 1) { + $conditions = ['OR' => $conditions]; + } + return $query->where($conditions); + } + + /** + * Se distingue de "archivalAgencyChilds" par la nécéssité que le role + * utilisateur doit avoir l'option "hierarchical_view" + * De plus, selon le type de l'entité de l'utilisateur, le lft/rght est soit + * sur le service d'archives, soit sur l'entité + * + * Applique une condition type : + * Model.lft >= ArchivalAgency.lft AND Model.rght >= ArchivalAgency.rght + * @param Query $query + * @param array $baseModels + * @return Query + */ + private function appendConditionsHierarchicalView(Query $query, array $baseModels): Query + { + $typeEntity = $this->getConfig('orgEntity.type_entity.code'); + if (empty($typeEntity)) { + throw new GenericException('orgEntity.type_entity is required'); + } + $query = $this->appendConditionsArchivalAgency($query, (array)current($baseModels)); + if (in_array($typeEntity, ['SA', 'CST'])) { + $lft = $this->getConfig('archivalAgency.lft'); + $rght = $this->getConfig('archivalAgency.rght'); + } elseif ($this->getConfig('user.role.hierarchical_view')) { + $lft = $this->getConfig('orgEntity.lft'); + $rght = $this->getConfig('orgEntity.rght'); + } else { + return $this->appendConditionsOrgEntity($query, $baseModels); + } + if (!$lft || !$rght) { + throw new GenericException('archivalAgency is required'); + } + $conditions = []; + foreach ($baseModels as $baseModel) { + $andCond = [ + "$baseModel.lft >=" => $lft, + "$baseModel.rght <=" => $rght, + ]; + if (count($baseModels) > 1) { + $conditions['OR'][] = $andCond; + } else { + $conditions[] = $andCond; + } + } + return $query->where($conditions); + } + + /** + * Applique une condition type : + * Model.org_entity_id = LoggedUser.org_entity_id + * @param Query $query + * @param array $baseModels + * @return Query + */ + private function appendConditionsOrgEntity(Query $query, array $baseModels): Query + { + $conditions = []; + foreach ($baseModels as $baseModel) { + $conditions["$baseModel.id"] = $this->getConfig('orgEntityId'); + } + if (count($conditions) > 1) { + $conditions = ['OR' => $conditions]; + } + return $query->where($conditions); + } + + /** + * Applique une condition type : + * Model.lft >= OrgEntity.lft AND Model.rght >= OrgEntity.rght + * @param Query $query + * @param array $baseModels + * @return Query + */ + private function appendConditionsOrgEntityChilds(Query $query, array $baseModels): Query + { + $lft = $this->getConfig('orgEntity.lft'); + $rght = $this->getConfig('orgEntity.rght'); + if (!$lft || !$rght) { + throw new GenericException('orgEntity is required'); + } + $conditions = []; + foreach ($baseModels as $baseModel) { + $conditions[] = [ + "$baseModel.lft >=" => $lft, + "$baseModel.rght <=" => $rght, + ]; + } + if (count($conditions) > 1) { + $conditions = ['OR' => $conditions]; + } + return $query->where($conditions); + } +} diff --git a/src/Model/Entity/Fileupload.php b/src/Model/Entity/Fileupload.php index 5ef9c6dd26ab74e45d3a7d0a4a90da04641d84aa..d7de099e0a318a7a984a38952a54e02ff79a9f86 100644 --- a/src/Model/Entity/Fileupload.php +++ b/src/Model/Entity/Fileupload.php @@ -163,7 +163,7 @@ class Fileupload extends Entity implements JsonSerializable protected function _setContent($value) { if (is_string($value) - && preg_match('/^[a-zA-Z0-9\/\r\n+]*={0,2}$/', $value) + && preg_match('/^[a-zA-Z\d\/\r\n+]*={0,2}$/', $value) && $decoded = base64_decode($value, true) ) { return $decoded; diff --git a/src/Model/Entity/IntervalTrait.php b/src/Model/Entity/IntervalTrait.php index 88b45806dac4d2032fd4313f5a0ed1638c15c1bf..b604137d4077f25e13d979a433b826443e34dff3 100644 --- a/src/Model/Entity/IntervalTrait.php +++ b/src/Model/Entity/IntervalTrait.php @@ -132,7 +132,7 @@ trait IntervalTrait if (empty($this->_fields[$field])) { return null; } - $num = preg_replace('/[\D]+/', '', $this->_fields[$field]); + $num = preg_replace('/\D+/', '', $this->_fields[$field]); return $num ?: null; } diff --git a/src/Model/Table/EaccpfsTable.php b/src/Model/Table/EaccpfsTable.php index 150df30de9ee082a49c7099928c2bc10df485508..200cf3f1f7907caa41b51e0bd10289f230696049 100644 --- a/src/Model/Table/EaccpfsTable.php +++ b/src/Model/Table/EaccpfsTable.php @@ -188,13 +188,13 @@ class EaccpfsTable extends Table || ($attr = $element->getAttribute('notBefore')) || ($attr = $element->getAttribute('notAfter')) ) { - if (preg_match('/^[\d]{4}$/', $attr)) { + if (preg_match('/^\d{4}$/', $attr)) { $format = '!Y'; - } elseif (preg_match('/^[\d]{4}-[\d]{2}$/', $attr)) { + } elseif (preg_match('/^\d{4}-\d{2}$/', $attr)) { $format = '!Y-m'; - } elseif (preg_match('/^[\d]{6}$/', $attr)) { + } elseif (preg_match('/^\d{6}$/', $attr)) { $format = '!Ym'; - } elseif (preg_match('/^[\d]{8}$/', $attr)) { + } elseif (preg_match('/^\d{8}$/', $attr)) { $format = '!Ymd'; } else { $format = '!Y-m-d'; @@ -202,13 +202,13 @@ class EaccpfsTable extends Table return \DateTime::createFromFormat($format, $attr); } // Si une date normé n'est pas trouvé, on tente de récupérer la date dans le texte - if (preg_match('/([\d]{4})-([\d]{1,2})-([\d]{1,2})/', $element->textContent, $matches)) { + if (preg_match('/(\d{4})-(\d{1,2})-(\d{1,2})/', $element->textContent, $matches)) { return \DateTime::createFromFormat('!Y-m-d', "$matches[1]-$matches[2]-$matches[3]"); - } elseif (preg_match('/([\d]{4})\/([\d]{1,2})\/([\d]{1,2})/', $element->textContent, $matches)) { + } elseif (preg_match('/(\d{4})\/(\d{1,2})\/(\d{1,2})/', $element->textContent, $matches)) { return \DateTime::createFromFormat('!Y-m-d', "$matches[1]-$matches[2]-$matches[3]"); - } elseif (preg_match('/([\d]{1,2})\/([\d]{1,2})\/([\d]{4})/', $element->textContent, $matches)) { + } elseif (preg_match('/(\d{1,2})\/(\d{1,2})\/(\d{4})/', $element->textContent, $matches)) { return \DateTime::createFromFormat('!Y-m-d', "$matches[3]-$matches[2]-$matches[1]"); - } elseif (preg_match('/([\d]{4})/', $element->textContent, $matches)) { + } elseif (preg_match('/(\d{4})/', $element->textContent, $matches)) { return \DateTime::createFromFormat('!Y', $matches[1]); } else { return null; @@ -251,9 +251,9 @@ class EaccpfsTable extends Table IntlDateFormatter::NONE ); $localFormat = preg_replace( - '/[^\w]/', + '/\W/', '', - preg_replace('/([\w])[\w]+/', '$1', strtolower($formatter->getPattern())) + preg_replace('/(\w)\w+/', '$1', strtolower($formatter->getPattern())) ); $validator->date('from_date', [$localFormat])->allowEmptyDate('from_date'); @@ -375,7 +375,7 @@ class EaccpfsTable extends Table libxml_use_internal_errors($initial); foreach ($extracted['errors'] as $error) { $msg = str_replace('{urn:isbn:1-931666-33-4}', '', $error['description']); - if (preg_match('/^DOMDocument::[\w]+\(\)(?: \[[^]]+])?: (.*)$/', $msg, $m)) { + if (preg_match('/^DOMDocument::\w+\(\)(?: \[[^]]+])?: (.*)$/', $msg, $m)) { $err = $this->translate($m[1]); $report[] = __("Erreur : {0}", $err); } else { @@ -398,7 +398,7 @@ class EaccpfsTable extends Table public function translate(string $string): string { if (preg_match( - "/^Namespace prefix ([\w:]+) for ([\w:]+) on source is not defined in Entity, line: ([\d]+)$/", + "/^Namespace prefix ([\w:]+) for ([\w:]+) on source is not defined in Entity, line: (\d+)$/", $string, $m ) diff --git a/src/Model/Table/MediainfosTable.php b/src/Model/Table/MediainfosTable.php index ad127ec9cf3bbabb62282b01bbf34fad363e034e..829704bae9ac39c84a7d1426d36745ef3270fe36 100644 --- a/src/Model/Table/MediainfosTable.php +++ b/src/Model/Table/MediainfosTable.php @@ -53,7 +53,7 @@ class MediainfosTable extends Table $mediainfo = $this->mediainfo($filename); foreach ($mediainfo as $category => $values) { - if (preg_match('/^([\w]+) #\d+$/', $category, $match)) { + if (preg_match('/^(\w+) #\d+$/', $category, $match)) { $category = end($match); } @@ -125,7 +125,7 @@ class MediainfosTable extends Table foreach ($output as $str) { if (strpos($str, ':')) { list($field, $value) = explode(':', $str, 2); - $result[$cat][preg_replace('/[\W]+/', '_', trim(strtolower($field)))] + $result[$cat][preg_replace('/\W+/', '_', trim(strtolower($field)))] = trim($value); } elseif (!empty($str)) { $cat = $str; diff --git a/src/Model/Table/OrgEntitiesTable.php b/src/Model/Table/OrgEntitiesTable.php index 2074a7222db13499819296cd23b71a514ecc2eed..4533432ec05b7d215080a91ecf80715bc2c1af60 100644 --- a/src/Model/Table/OrgEntitiesTable.php +++ b/src/Model/Table/OrgEntitiesTable.php @@ -6,7 +6,7 @@ namespace AsalaeCore\Model\Table; use ArrayObject; -use Asalae\Controller\Component\SealComponent; +use AsalaeCore\Controller\Component\SealComponent; use AsalaeCore\Controller\Component\ConditionComponent; use AsalaeCore\Form\MessageSchema\MessageSchema; use AsalaeCore\Model\Entity\OrgEntity; diff --git a/src/Model/Table/UsersTable.php b/src/Model/Table/UsersTable.php index 7a7f2a5b9977296d627cb5c3290449223639b024..acf1a70979188ff5525187dcc599f37288c3c8c3 100644 --- a/src/Model/Table/UsersTable.php +++ b/src/Model/Table/UsersTable.php @@ -300,7 +300,7 @@ class UsersTable extends Table implements AfterSaveInterface $targetComplexity = Configure::read('Password.complexity', 78); do { $password = preg_replace( - '/[\W]+/', + '/\W+/', '', base64_encode(random_bytes($bytes)) ); diff --git a/src/Utility/HashUtility.php b/src/Utility/HashUtility.php index 182502f719fbd1b17d4bc905b36eaaac148e96f3..e7e2523f561c51c08dc0b06d7f9eea9c6715b76e 100644 --- a/src/Utility/HashUtility.php +++ b/src/Utility/HashUtility.php @@ -31,9 +31,9 @@ class HashUtility if (strpos($algo, '#') !== false) { list(, $algo) = explode('#', $algo); } - $formatedAlgo = strtolower(preg_replace('/[^a-zA-Z0-9]+/', '', $algo)); + $formatedAlgo = strtolower(preg_replace('/[^a-zA-Z\d]+/', '', $algo)); foreach (hash_algos() as $algo) { - $formated = strtolower(preg_replace('/[^a-zA-Z0-9]+/', '', $algo)); + $formated = strtolower(preg_replace('/[^a-zA-Z\d]+/', '', $algo)); if ($formatedAlgo === $formated) { return $algo; } diff --git a/src/Utility/Timestamper.php b/src/Utility/Timestamper.php index 93e6538d7d0bdad45d9f3a86af7a093a1446f3c6..a747611a67673c62478172bccf1804412cee6b7a 100644 --- a/src/Utility/Timestamper.php +++ b/src/Utility/Timestamper.php @@ -245,7 +245,7 @@ class Timestamper $data['hash_algo'] = trim(substr($str, 16)); } elseif ($str === 'Message data:') { $hash = true; - } elseif ($hash && preg_match('/\d{4}[ -]+((?:[a-f0-9]{2}[ -]?)+)/', $str, $m)) { + } elseif ($hash && preg_match('/\d{4}[ -]+((?:[a-f\d]{2}[ -]?)+)/', $str, $m)) { $data['hash'] .= str_replace([' ', '-'], '', $m[1]); } elseif (substr($str, 0, 11) === 'Time stamp:') { $data['timestamp'] = new DateTime(trim(substr($str, 12))); diff --git a/src/View/Helper/Object/Filter.php b/src/View/Helper/Object/Filter.php index 7bcacd361f1f378344124c04b3590852548fe090..51e2f5c7084608ce9e736c0d6629e313ee6cdffe 100644 --- a/src/View/Helper/Object/Filter.php +++ b/src/View/Helper/Object/Filter.php @@ -92,7 +92,7 @@ class Filter implements ObjectInterface { $this->Helper = $helper; $this->id = Inflector::camelize( - preg_replace('/[\W]/', '_', $id) + preg_replace('/\W/', '_', $id) ); $this->urls = array_map( function ($v) { @@ -537,7 +537,7 @@ class Filter implements ObjectInterface foreach ($save->get('filters') as $filter) { $key = $filter->get('key'); /** @var \AsalaeCore\Model\Entity\Filter $filter */ - if (preg_match('/\[([\d]+)](?:\[([\d]+)])*$/', $key, $match)) { + if (preg_match('/\[(\d+)](?:\[(\d+)])*$/', $key, $match)) { $index = $match[1]; $multiVal = $match[2] ?? null; $key = substr($key, 0, strrpos($key, $match[0])); diff --git a/src/View/Helper/Object/Table.php b/src/View/Helper/Object/Table.php index 213ab956864ab124e9ae41e99c027950925ca419..d1a8e8a841e82e887a33990a0b85a25d87a7846b 100644 --- a/src/View/Helper/Object/Table.php +++ b/src/View/Helper/Object/Table.php @@ -564,7 +564,7 @@ EOD; $label = !isset($params['label']) ? $fieldname : $params['label']; $value = [ - '_id' => preg_replace('/[\W]/', '_', $fieldname), + '_id' => preg_replace('/\W/', '_', $fieldname), 'label' => $label, 'title' => Hash::get($params, 'title', ''), 'link' => Hash::get($params, 'link', false), diff --git a/src/View/Helper/Object/Upload.php b/src/View/Helper/Object/Upload.php index 7b7f2e86d308ada5fd5c97a78acaebd0bb1902b0..0d078dcd128ae6482d23b440f97383516932c42c 100644 --- a/src/View/Helper/Object/Upload.php +++ b/src/View/Helper/Object/Upload.php @@ -91,7 +91,7 @@ class Upload implements ObjectInterface $this->dropboxId = $domId; $this->table = new Table($this->Helper->Table, $this->Helper->getTableId($domId), $params); $this->jsObject = Inflector::camelize( - 'uploader_'.preg_replace('/[^\w]/', '_', $this->dropboxId) + 'uploader_'.preg_replace('/\W/', '_', $this->dropboxId) ); $this->params = $params; } diff --git a/src/View/Helper/TableHelper.php b/src/View/Helper/TableHelper.php index f77fca73dceb12a4835ec4edeaf45bbc904fff79..6927b3b23d6d065ba6184f114e288f1776ffd94c 100644 --- a/src/View/Helper/TableHelper.php +++ b/src/View/Helper/TableHelper.php @@ -85,7 +85,7 @@ class TableHelper extends Helper implements ObjectHelperInterface public function getJsTableObject(string $id): string { return Inflector::camelize( - 'generated_'.preg_replace('/[^\w]/', '_', $id) + 'generated_'.preg_replace('/\W/', '_', $id) ); } } diff --git a/webroot/xmlSchemas/seda_v2-2/Dictionnaire_SEDA2_2_index_jvr2022.docx b/webroot/xmlSchemas/seda_v2-2/Dictionnaire_SEDA2_2_index_jvr2022.docx new file mode 100644 index 0000000000000000000000000000000000000000..cd01037996e0551f6cdaa9088c55856e178078e5 Binary files /dev/null and b/webroot/xmlSchemas/seda_v2-2/Dictionnaire_SEDA2_2_index_jvr2022.docx differ diff --git a/webroot/xmlSchemas/seda_v2-2/README.md b/webroot/xmlSchemas/seda_v2-2/README.md new file mode 100644 index 0000000000000000000000000000000000000000..2e4ec2d81de44e23d2f418991f7cbc512e976ab5 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/README.md @@ -0,0 +1,24 @@ +# Standard d'échange de données pour l'archivage (SEDA) +Cette version 2.2 du Standard d'échanges de données pour l'archivage (SEDA) publiée en janvier 2022 sous l'égide du Service interministériel des Archives de France, +comprend six schémas et un dictionnaire. +Ils sont le fruit du travail mené en 2020-2021 par le Comité de pilotage du SEDA, qui rassemble des acteurs œuvrant pour l’utilisation de ce standard d'échange +dans les services publics d’archives, chez les tiers-archiveurs, les éditeurs de logiciels d’archivage électronique ou encore les cabinets spécialisés dans +l'accompagnement de projets d'archivage électronique. + +Le SEDA modélise 6 transactions qui peuvent avoir lieu entre des acteurs dans le cadre de l'archivage de données : +le transfert, la demande de transfert, la modification, l'élimination, la communication et la restitution. +Les présents schémas traduisent formellement la forme des messages échangés au cours des transactions. +Ils ont été réalisés par le Cabinet Mintika à partir des principes définis en Comité de pilotage. +Les principaux changements par rapport à la version 2.1 publiée en juin 2018 sur https://francearchives.fr/seda/ +sont: +- Modification de AgentType générique dans l’ontologie; +- Dépréciation de AgentAbstract; +- Ajout d'une nouvelle règle de gestion HoldRule dans les métadonnées de gestion; +- Ajout de HoldRuleCodeListVersion; +- Ajout de OriginatingSystemIdReplyToGroup et de TextContent (pour les mails); +- Ajout de LinkingAgentIdentifierType dans les Event; +- Ajout de DataObjectProfile dans les métadonnées techniques; +- Ajout de DateLitteral dans l’ontologie; +- Modification du type de MessageIdentifier (devient NonEmptyToken). + +Le dictionnaire des balises SEDA est proposé quant à lui dans une version de travail. Il synthétise par grands ensembles de métadonnées (gestion, description, technique, transport et typologie de messages) les éléments présents dans les schémas du standard. diff --git a/webroot/xmlSchemas/seda_v2-2/asalae-seda-2.2-archive.xsd b/webroot/xmlSchemas/seda_v2-2/asalae-seda-2.2-archive.xsd new file mode 100755 index 0000000000000000000000000000000000000000..541e23135c1e27f393b18ca14c17eecc030bc51b --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/asalae-seda-2.2-archive.xsd @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" elementFormDefault="qualified" + attributeFormDefault="unqualified" version="1.0"> + <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/> + <xsd:import namespace="http://www.w3.org/1999/xlink" schemaLocation="xlink.xsd"/> + + <xsd:include schemaLocation="seda-2.2-main.xsd"/> + + <xsd:element name="Archive" type="DataObjectPackageType"/> +</xsd:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/seda-2.2-descriptive.xsd b/webroot/xmlSchemas/seda_v2-2/seda-2.2-descriptive.xsd new file mode 100644 index 0000000000000000000000000000000000000000..d17b8b309d5c542ba51c93b80873af212ed6c264 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/seda-2.2-descriptive.xsd @@ -0,0 +1,76 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:xlink="http://www.w3.org/1999/xlink" xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" + elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.0"> + <xsd:include schemaLocation="seda-2.2-types.xsd"/> + <xsd:include schemaLocation="seda-2.2-management.xsd"/> + <xsd:include schemaLocation="seda-2.2-ontology.xsd"/> + + <!-- Hierarchy and recursivity --> + <xsd:complexType name="ArchiveUnitType"> + <xsd:annotation> + <xsd:documentation>Unité de base des métadonnées de description contenant la gestion de l'arborescence.</xsd:documentation> + </xsd:annotation> + <xsd:choice> + <xsd:element name="ArchiveUnitRefId" type="ArchiveUnitRefIdType"> + <xsd:annotation> + <xsd:documentation>Permet de faire une référence à d'autres ArchiveUnit dans la même transaction.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:sequence> + <xsd:element name="ArchiveUnitProfile" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Référence à une partie d'un profil d’archivage applicable à un ArchiveUnit en particulier. Permet par exemple de faire référence à une typologie documentaire dans un profil d'archivage.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Management" type="ManagementType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Métadonnées de gestion applicables à l’ArchiveUnit concernée et à ses héritiers.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Content" type="DescriptiveMetadataContentType" minOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnées de description associées à un ArchiveUnit.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <!-- Hierarchy --> + <xsd:choice minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="ArchiveUnit" type="ArchiveUnitType"> + <xsd:annotation> + <xsd:documentation>Gestion de la récursivité. Une ArchiveUnit peut être contenu dans une ature ArchiveUnit.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element ref="ArchiveUnitReferenceAbstract"> + <xsd:annotation> + <xsd:documentation>Permet de faire référence à une sous unité d'archives, pouvant être déjà présente dans le système d'archivage provenant d'une transaction précédente.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectReference" type="DataObjectRefType"> + <xsd:annotation> + <xsd:documentation>Permet de faire référence à un objet-donnée binaire ou physique déjà présent dans les métadonnées du bordereau.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + </xsd:choice> + <xsd:attribute name="id" type="ArchiveUnitIdType" use="required"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité d'archives utilisé par exemple dans le cas de multiples héritages, pour savoir quel noeud contient une erreur.</xsd:documentation> + </xsd:annotation> + </xsd:attribute> + </xsd:complexType> + <xsd:complexType name="ManagementType"> + <xsd:group ref="ManagementGroup"/> + </xsd:complexType> + + <!-- In ArchiveUnitType from seda-2.2-descriptive.xsd: Descriptive Metadata Content --> + <xsd:complexType name="DescriptiveMetadataContentType"> + <xsd:annotation> + <xsd:documentation>Permet de définir les métadonnées de description. Peut être étendu.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="ObjectGroup"/> + </xsd:sequence> + </xsd:complexType> + +</xsd:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/seda-2.2-main.xsd b/webroot/xmlSchemas/seda_v2-2/seda-2.2-main.xsd new file mode 100644 index 0000000000000000000000000000000000000000..03bf12c271190b09834bf44638652bf99c166eca --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/seda-2.2-main.xsd @@ -0,0 +1,982 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" elementFormDefault="qualified" + attributeFormDefault="unqualified" version="1.0"> + + <!--<xsd:import namespace="http://www.w3.org/XML/1998/namespace" + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + <xsd:import namespace="http://www.w3.org/1999/xlink" + schemaLocation="http://www.w3.org/1999/xlink.xsd"/>--> + <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/> + <xsd:import namespace="http://www.w3.org/1999/xlink" schemaLocation="xlink.xsd"/> + + <!-- + ***************************** + *** Types de base + ***************************** + --> + <xsd:include schemaLocation="seda-2.2-types.xsd"/> + <!-- + ***************************** + *** Base technique + ***************************** + --> + <xsd:include schemaLocation="seda-2.2-technical.xsd"/> + <!-- + ***************************** + *** Base de gestion + ***************************** + --> + <xsd:include schemaLocation="seda-2.2-management.xsd"/> + <!-- + ***************************** + *** Base descriptive + ***************************** + --> + <xsd:include schemaLocation="seda-2.2-descriptive.xsd"/> + + <!-- + ***************************** + *** Code List + ***************************** + + --> + <!-- Liste des versions des référentiels issue de MEDONA --> + <xsd:group name="TransportCodeListsGroup"> + <xsd:annotation> + <xsd:documentation>Liste des codes de réponses souhaitée par + l'expéditeur.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="ReplyCodeListGroup"/> + </xsd:sequence> + </xsd:group> + <!-- Reply Code list --> + <xsd:group name="ReplyCodeListGroup"> + <xsd:sequence> + <xsd:element name="ReplyCodeListVersion" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Liste des codes de réponses à utiliser.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="ReplyCodeType"> + <xsd:annotation> + <xsd:documentation>Code de réponses spécifié dans la liste de + réponses.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + + + <!-- Liste des versions des référentiels utilisés globalement --> + <xsd:complexType name="CodeListVersionsType"> + <xsd:sequence> + <xsd:group ref="TransportCodeListsGroup"/> + <xsd:group ref="TechnicalCodeListsGroup"/> + <xsd:group ref="ManagementCodeListsGroup"/> + <xsd:element name="AcquisitionInformationCodeListVersion" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version de la liste de codes des modalités + d'entrée.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="AuthorizationReasonCodeListVersion" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version de la liste de codes + d'autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="RelationshipCodeListVersion" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version de la liste de codes des + relations.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element ref="OtherCodeListAbstract" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Permet d'ajouter de nouvelles listes de codes si l'ajout + d'autres métadonnées l'impose.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:attribute ref="xml:id" use="optional"/> + </xsd:complexType> + + <!-- + ***************************** + *** Types métier + ***************************** + + --> + + <!-- Groupe d'objets-données SEDA 2.2 --> + <xsd:complexType name="DataObjectGroupType"> + <xsd:sequence> + <xsd:choice minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="BinaryDataObject" type="BinaryDataObjectType"> + <xsd:annotation> + <xsd:documentation>Bloc de métadonnées techniques des objets-données + numériques. Le caractère facultatif est requis afin de permettre le + transfert d'un plan de classement sans DataObject + joint.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="PhysicalDataObject" type="PhysicalDataObjectType"> + <xsd:annotation> + <xsd:documentation>Bloc de métadonnées techniques des objets-données + physiques.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + <xsd:element name="LogBook" type="LogBookOgType" minOccurs="0"/> + </xsd:sequence> + <xsd:attribute name="id" type="GroupIdType" use="required"/> + </xsd:complexType> + <xsd:complexType name="LogBookOgType"> + <xsd:sequence> + <xsd:element name="Event" type="EventLogBookOgType" minOccurs="0" maxOccurs="unbounded"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="EventLogBookOgType"> + <xsd:complexContent> + <xsd:extension base="EventType"> + <xsd:sequence> + <xsd:element name="DataObjectReferenceId" type="DataObjectRefIdType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Permet de faire référence à un objet-donnée binaire ou physique déjà présent dans les métadonnées du bordereau.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- Paquet d'Objets-données --> + <xsd:complexType name="DataObjectPackageType"> + <xsd:sequence> + <xsd:choice minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="DataObjectGroup" type="DataObjectGroupType"/> + <xsd:choice minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="BinaryDataObject" type="BinaryDataObjectType"> + <xsd:annotation> + <xsd:documentation>Bloc de métadonnées techniques des objets-données + numériques. Le caractère facultatif est requis afin de permettre le + transfert d'un plan de classement sans DataObject + joint.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="PhysicalDataObject" type="PhysicalDataObjectType"> + <xsd:annotation> + <xsd:documentation>Bloc de métadonnées techniques des objets-données + physiques.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:choice> + <xsd:element name="DescriptiveMetadata" type="DescriptiveMetadataType"> + <xsd:annotation> + <xsd:documentation>Bloc de métadonnées descriptives des + objets-données.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ManagementMetadata" type="ManagementMetadataType"> + <xsd:annotation> + <xsd:documentation>Bloc des métadonnées de gestion par défaut des + objets-données.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:attribute ref="xml:id" use="optional"/> + </xsd:complexType> + + <!-- Métadonnées de gestion --> + <xsd:complexType name="ManagementMetadataType"> + <xsd:sequence> + <xsd:element name="ArchivalProfile" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Profil d’archivage applicable aux + ArchiveUnit.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ServiceLevel" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Niveau de service applicable aux unités + d’archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="AcquisitionInformation" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Modalités d'entrée des archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="LegalStatus" type="LegalStatusType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Statut des archives échangées.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgencyIdentifier" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant du service producteur - information de gestion à + ne pas confondre avec OriginatingAgency dans les métadonnées de + description.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="SubmissionAgencyIdentifier" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant du service versant - information de gestion à ne + pas confondre avec SubmissionAgency dans les métadonnées de + description.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:group ref="ManagementGroup" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Métadonnées de gestion associées à l'ensemble des unités + d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:group> + </xsd:sequence> + <xsd:attribute ref="xml:id" use="optional"/> + </xsd:complexType> + + + <!-- ========================================================= --> + <!-- ===== Code List LegalStatusType: LegalStatus Code ======= --> + <!-- ========================================================= --> + <xsd:simpleType name="LegalStatusType"> + <xsd:annotation> + <xsd:documentation>Valeurs de LegalStatus.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:token"> + <xsd:enumeration value="Public Archive"/> + <xsd:enumeration value="Private Archive"/> + <xsd:enumeration value="Public and Private Archive"/> + </xsd:restriction> + </xsd:simpleType> + + <!-- Demande d'autorisation --> + <xsd:complexType name="AuthorizationRequestContentType"> + <xsd:sequence> + <xsd:element name="AuthorizationReason" type="xsd:token"> + <xsd:annotation> + <xsd:documentation>Motif de l'autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Comment" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Commentaire sur la transaction.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="RequestDate" type="xsd:date"> + <xsd:annotation> + <xsd:documentation>Date de la demande d'autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité documentaire.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Requester" type="OrganizationType"> + <xsd:annotation> + <xsd:documentation>Demandeur de l'autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="AuthorizationRequestReply" + type="BusinessAuthorizationRequestReplyMessageType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Réponse à la demande d’autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:attribute ref="xml:id" use="optional"/> + </xsd:complexType> + + <!-- + ***************************** + *** Base de l'arborescence + ***************************** + --> + + <!-- Métadonnées descriptives pour un paquet d'Objets-données --> + <xsd:complexType name="DescriptiveMetadataType"> + <xsd:sequence> + <xsd:element name="ArchiveUnit" type="ArchiveUnitType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Correspond à la notion de composant en ISAD(G). ArchiveUnit + permet à la fois de gérer la hiérarchie intellectuelle, tout en contenant + les métadonnées de description et de gestion propres à chaque niveau de + description archivistique.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <!-- + ***************************** + *** Déclaration des types de message + ***************************** + --> + + <!-- Message --> + <xsd:complexType name="MessageType" abstract="true"> + <xsd:sequence> + <xsd:element name="Comment" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Commentaire sur le message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Date" type="xsd:dateTime"> + <xsd:annotation> + <xsd:documentation>Date du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="MessageIdentifier" type="IdentifierType"> + <xsd:annotation> + <xsd:documentation>Identifiant du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Signature" type="SignatureMessageType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Signature du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:attribute ref="xml:id" use="optional"/> + </xsd:complexType> + + + <!-- Message métier --> + <xsd:complexType name="BusinessMessageType" abstract="true"> + <xsd:complexContent> + <xsd:extension base="MessageType"> + <xsd:sequence> + <xsd:element name="ArchivalAgreement" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Accord de service.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="CodeListVersions" type="CodeListVersionsType"> + <xsd:annotation> + <xsd:documentation>Listes de codes de références utilisés dans le + message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectPackage" type="DataObjectPackageType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Objets-données échangés dans le + message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- Message de demande --> + <xsd:complexType name="BusinessRequestMessageType" abstract="true"> + <xsd:complexContent> + <xsd:extension base="BusinessMessageType"/> + </xsd:complexContent> + </xsd:complexType> + + <!-- Message de demande d'autorisation --> + <xsd:complexType name="BusinessAuthorizationRequestMessageType" abstract="true"> + <xsd:complexContent> + <xsd:extension base="BusinessRequestMessageType"> + <xsd:sequence> + <xsd:element name="AuthorizationRequestContent" + type="AuthorizationRequestContentType"> + <xsd:annotation> + <xsd:documentation>Demande d’autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- Message de reponse à une demande --> + <xsd:complexType name="BusinessReplyMessageType" abstract="true"> + <xsd:complexContent> + <xsd:extension base="BusinessMessageType"> + <xsd:sequence> + <xsd:element name="ReplyCode" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Code de la réponse.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Operation" type="OperationType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Liste des événements dans les messages de + réponse</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="MessageRequestIdentifier" type="IdentifierType"> + <xsd:annotation> + <xsd:documentation>Identifiant de la demande.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- Liste des opérations dans les messages de réponse --> + <xsd:complexType name="OperationType"> + <xsd:sequence> + <xsd:element name="Event" type="EventType" minOccurs="0" maxOccurs="unbounded"/> + </xsd:sequence> + </xsd:complexType> + + <!-- Message de demande d'autorisation --> + <xsd:complexType name="BusinessAuthorizationRequestReplyMessageType" abstract="true"> + <xsd:complexContent> + <xsd:extension base="BusinessReplyMessageType"/> + </xsd:complexContent> + </xsd:complexType> + + <!-- Message de notification --> + <xsd:complexType name="BusinessNotificationMessageType" abstract="true"> + <xsd:complexContent> + <xsd:extension base="BusinessMessageType"/> + </xsd:complexContent> + </xsd:complexType> + + <!-- Défintion des organisations avec Id --> + <xsd:complexType name="OrganizationWithIdType"> + <xsd:complexContent> + <xsd:extension base="OrganizationType"> + <xsd:attribute ref="xml:id" use="optional"/> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + + <!-- + ***************************** + *** Le message d'accusé de réception + ***************************** + --> + <xsd:element name="Acknowledgement" type="AcknowledgementType"> + <xsd:annotation> + <xsd:documentation>Accusé de réception d'un message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="AcknowledgementType"> + <xsd:complexContent> + <xsd:extension base="MessageType"> + <xsd:sequence> + <xsd:element name="MessageReceivedIdentifier" type="IdentifierType"> + <xsd:annotation> + <xsd:documentation>Identifiant du message reçu.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Sender" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Expéditeur du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Receiver" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Destinataire du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- + ***************************** + *** Les messages de requete + ***************************** + --> + <!-- Message de demande de communication --> + <xsd:element name="ArchiveDeliveryRequest" type="ArchiveDeliveryRequestType"> + <xsd:annotation> + <xsd:documentation>Demande de communication d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveDeliveryRequestType"> + <xsd:complexContent> + <xsd:extension base="BusinessRequestMessageType"> + <xsd:sequence> + <xsd:element name="Derogation" type="xsd:boolean"> + <xsd:annotation> + <xsd:documentation>Indique si une procédure de dérogation est nécessaire + avant de communiquer l’unité d'archive.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité d'archive.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la + communication.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Requester" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Demandeur de la communication.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de demande de restitution --> + <xsd:element name="ArchiveRestitutionRequest" type="ArchiveRestitutionRequestType"> + <xsd:annotation> + <xsd:documentation>Demande de restitution d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveRestitutionRequestType"> + <xsd:complexContent> + <xsd:extension base="BusinessRequestMessageType"> + <xsd:sequence> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité + d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la + restitution.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service producteur demandant la + restitution.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de transfert (attention le paquet de données est facultatif)--> + <xsd:element name="ArchiveTransfer" type="ArchiveTransferType"> + <xsd:annotation> + <xsd:documentation>Transfert d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveTransferType"> + <xsd:complexContent> + <xsd:extension base="BusinessRequestMessageType"> + <xsd:sequence> + <xsd:element name="RelatedTransferReference" type="IdentifierType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant d’un transfert + associé.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferRequestReplyIdentifier" type="IdentifierType" + minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant de la réponse à une demande de + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable du + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferringAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service versant chargé de réaliser le + transport.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de demande de transfert --> + <xsd:element name="ArchiveTransferRequest" type="ArchiveTransferRequestType"> + <xsd:annotation> + <xsd:documentation>Demande de transfert d’archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveTransferRequestType"> + <xsd:complexContent> + <xsd:extension base="BusinessRequestMessageType"> + <xsd:sequence> + <xsd:element name="RelatedTransferReference" type="IdentifierType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Référence à un transfert d'archives + lié.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferDate" type="xsd:dateTime" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date retenue pour le transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable du + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferringAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service versant responsable du + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- + ***************************** + *** Les messages de demande d'autorisation + ***************************** + --> + <!-- Message de demande d'autorisation au service de contrôle --> + <xsd:element name="AuthorizationControlAuthorityRequest" + type="AuthorizationControlAuthorityRequestType"> + <xsd:annotation> + <xsd:documentation>Demande d'autorisation au service de contrôle.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="AuthorizationControlAuthorityRequestType"> + <xsd:complexContent> + <xsd:extension base="BusinessAuthorizationRequestMessageType"> + <xsd:sequence> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la demande + d'autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ControlAuthority" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Autorité de contrôle.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de demande d'autorisation au service producteur --> + <xsd:element name="AuthorizationOriginatingAgencyRequest" + type="AuthorizationOriginatingAgencyRequestType"> + <xsd:annotation> + <xsd:documentation>Demande d'autorisation au service producteur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="AuthorizationOriginatingAgencyRequestType"> + <xsd:complexContent> + <xsd:extension base="BusinessAuthorizationRequestMessageType"> + <xsd:sequence> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la demande + d'autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service producteur responsable de l’instruction de la + demande d’autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- + ***************************** + *** Les messages de reponse à une requete + ***************************** + --> + <!-- Message de réponse à une demande de communication --> + <xsd:element name="ArchiveDeliveryRequestReply" type="ArchiveDeliveryRequestReplyType"> + <xsd:annotation> + <xsd:documentation>Réponse à une demande de communication + d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveDeliveryRequestReplyType"> + <xsd:complexContent> + <xsd:extension base="BusinessReplyMessageType"> + <xsd:sequence> + <xsd:element name="AuthorizationRequestReplyIdentifier" type="IdentifierType" + minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant de la réponse à une demande + d’autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité d'archive.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la demande de + communication.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Requester" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Demandeur de la communication.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de réponse à une demande de restitution --> + <xsd:element name="ArchiveRestitutionRequestReply" type="ArchiveRestitutionRequestReplyType"> + <xsd:annotation> + <xsd:documentation>Réponse à une demande de restitution d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveRestitutionRequestReplyType"> + <xsd:complexContent> + <xsd:extension base="BusinessReplyMessageType"> + <xsd:sequence> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité d'archive.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la demande de + restitution.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service producteur responsable de la demande de + restitution.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de réponse à un transfert --> + <xsd:element name="ArchiveTransferReply" type="ArchiveTransferReplyType"> + <xsd:annotation> + <xsd:documentation>Réponse à un transfert d'archives (acceptation, rejet, + anomalie...).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveTransferReplyType"> + <xsd:complexContent> + <xsd:extension base="BusinessReplyMessageType"> + <xsd:sequence> + <xsd:element name="GrantDate" type="xsd:dateTime" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de prise en charge effective du + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la réponse à un + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferringAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service versant responsable de la réponse à un + transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de réponse à une demande de transfert --> + <xsd:element name="ArchiveTransferRequestReply" type="ArchiveTransferRequestReplyType"> + <xsd:annotation> + <xsd:documentation>Réponse à une demande de transfert d’archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveTransferRequestReplyType"> + <xsd:complexContent> + <xsd:extension base="BusinessReplyMessageType"> + <xsd:sequence> + <xsd:element name="TransferDate" type="xsd:dateTime" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la réponse à une + demande de transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferringAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service versant responsable de la réponse à une + demande de transfert.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- + ***************************** + *** Les messages de reponse à une demande d'autorisation + ***************************** + --> + <!-- Message de réponse à une demande d'autorisation au service de contrôle --> + <xsd:element name="AuthorizationControlAuthorityRequestReply" + type="AuthorizationControlAuthorityRequestReplyType"> + <xsd:annotation> + <xsd:documentation>Réponse donnée à une demande d'autorisation au service de + contrôle.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="AuthorizationControlAuthorityRequestReplyType"> + <xsd:complexContent> + <xsd:extension base="BusinessAuthorizationRequestReplyMessageType"> + <xsd:sequence> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la réponse à une + demande d'autorisation à un service de contrôle.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ControlAuthority" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service de contrôle responsable de la réponse à une + demande d'autorisation à un service de contrôle.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <!-- Message de réponse à une demande d'autorisation au service producteur --> + <xsd:element name="AuthorizationOriginatingAgencyRequestReply" + type="AuthorizationOriginatingAgencyRequestReplyType"> + <xsd:annotation> + <xsd:documentation>Réponse donnée à une demande d'autorisation au service + producteur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="AuthorizationOriginatingAgencyRequestReplyType"> + <xsd:complexContent> + <xsd:extension base="BusinessAuthorizationRequestReplyMessageType"> + <xsd:sequence> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d’archives à l’origine de la demande + d’autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service producteur responsable de l’instruction de la + demande d’autorisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- + ***************************** + *** Les messages de notification + ***************************** + --> + <!-- Message de notification d'élimination --> + <xsd:element name="ArchiveDestructionNotification" type="ArchiveDestructionNotificationType"> + <xsd:annotation> + <xsd:documentation>Notification d'élimination d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveDestructionNotificationType"> + <xsd:complexContent> + <xsd:extension base="BusinessNotificationMessageType"> + <xsd:sequence> + <xsd:element name="AuthorizationRequestReplyIdentifier" type="IdentifierType"> + <xsd:annotation> + <xsd:documentation>Identifiant de la réponse à une demande + d'autorisation d'élimination.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité d'archive.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la notification + d'élimination.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service producteur responsable de la notification + d'élimination.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- Message de notification de modification --> + <xsd:element name="ArchiveModificationNotification" type="ArchiveModificationNotificationType"> + <xsd:annotation> + <xsd:documentation>Notification de modification d'archives (format ou + métadonnées).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:complexType name="ArchiveModificationNotificationType"> + <xsd:complexContent> + <xsd:extension base="BusinessNotificationMessageType"> + <xsd:sequence> + <xsd:element name="UnitIdentifier" type="IdentifierType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'unité + d'archives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service d'archives responsable de la notification de + modification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgency" type="OrganizationWithIdType"> + <xsd:annotation> + <xsd:documentation>Service producteur responsable de la notification de + modification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + +</xsd:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/seda-2.2-management.xsd b/webroot/xmlSchemas/seda_v2-2/seda-2.2-management.xsd new file mode 100644 index 0000000000000000000000000000000000000000..59f17ff12babbfb2ca63adac76de44dd2762534d --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/seda-2.2-management.xsd @@ -0,0 +1,517 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema + targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" + elementFormDefault="qualified" + attributeFormDefault="unqualified" + version="1.0"> + <xsd:include schemaLocation="seda-2.2-types.xsd"/> + + <!-- + ***************************** + *** Code List + ***************************** + + --> + <xsd:group name="ManagementCodeListsGroup"> + <xsd:annotation> + <xsd:documentation>Listes de codes nécessaires dans les métadonnées de gestion.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="StorageRuleCodeListGroup" minOccurs="0"/> + <xsd:group ref="AppraisalRuleCodeListGroup" minOccurs="0"/> + <xsd:group ref="AccessRuleCodeListGroup" minOccurs="0"/> + <xsd:group ref="DisseminationRuleCodeListGroup" minOccurs="0"/> + <xsd:group ref="ReuseRuleCodeListGroup" minOccurs="0"/> + <xsd:group ref="ClassificationRuleCodeListGroup" minOccurs="0"/> + <xsd:group ref="HoldRuleCodeListGroup" minOccurs="0"/> + </xsd:sequence> + </xsd:group> + + <!-- Management Lists and Codes --> + <xsd:complexType name="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant de la règle de gestion.</xsd:documentation> + </xsd:annotation> + <xsd:simpleContent> + <xsd:extension base="NonEmptyTokenType"> + <xsd:attribute name="id" type="xsd:ID" use="optional"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + + <xsd:group name="AccessRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="AccessRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de communicabilité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <xsd:group name="DisseminationRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="DisseminationRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de diffusion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <xsd:group name="ReuseRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="ReuseRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de réutilisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <xsd:group name="ClassificationRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="ClassificationRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <xsd:group name="AppraisalRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="AppraisalRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de durée d'utilité administrative.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <xsd:group name="StorageRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="StorageRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de durée d'utilité courante.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <xsd:group name="HoldRuleCodeListGroup"> + <xsd:sequence> + <xsd:element name="HoldRuleCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version des listes de codes pour les règles de gel.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Management content --> + <xsd:group name="ManagementGroup"> + <xsd:annotation> + <xsd:documentation>Contient les métadonnées de gestion.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="StorageRule" type="StorageRuleType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la durée d’utilité courante.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="AppraisalRule" type="AppraisalRuleType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la durée d’utilité administrative.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="AccessRule" type="AccessRuleType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la communicabilité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DisseminationRule" type="DisseminationRuleType" + minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la diffusion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ReuseRule" type="ReuseRuleType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la réutilisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ClassificationRule" type="ClassificationRuleType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="LogBook" type="LogBookType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion des traces.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="NeedAuthorization" type="xsd:boolean" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique si une autorisation humaine est nécessaire pour vérifier ou valider les opérations de gestion des ArchiveUnit.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="HoldRule" type="HoldRuleType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Gestion de la durée de gel des ArchiveUnits.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element ref="OtherManagementAbstract" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Autres métadonnées de gestion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="LogBookType"> + <xsd:sequence> + <xsd:element name="Event" type="EventType" maxOccurs="unbounded"/> + </xsd:sequence> + </xsd:complexType> + + <!-- Global inheritance control --> + <xsd:group name="PreventInheritanceGroup"> + <xsd:choice> + <xsd:element name="PreventInheritance" type="xsd:boolean" default="false" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique si les règles de gestion héritées des ArchiveUnit parents doivent être ignorées pour l’ArchiveUnit concerné.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:group> + + <xsd:complexType name="AccessRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la communicabilité.</xsd:documentation> + <xsd:documentation>Chaque règle a une startDate et un Identifiant de règle de référence pour la durée. + Si aucune règle n'est spécifiée et que la date actuelle est dans la StarDate, la réponse de restriction est "Aucune restriction". + Si la date est vide, la réponse de restriction est "Restreint" car il n'y a aucun moyen de calculer la date de fin. + Si une règle et une date sont précisées, alors la date de fin d'application de la règle peut être calculée et comparée avec la date courante..</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:sequence minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de communicabilité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de départ de calcul de la règle de communicabilité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de la règle à désactiver à partir de cette ArchiveUnit.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="DisseminationRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la diffusion.</xsd:documentation> + <xsd:documentation>Chaque règle a une startDate et un Identifiant de règle de référence pour la durée. + Si aucune règle n'est spécifiée et que la date actuelle est dans la StarDate, la réponse de restriction est "Aucune restriction". + Si la date est vide, la réponse de restriction est "Restreint" car il n'y a aucun moyen de calculer la date de fin. + Si une règle et une date sont précisées, alors la règle est valable (restriction appliquée).</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:sequence minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de diffusion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de départ de calcul de la règle de diffusion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>L'identifiant de la règle spécifiée pourra être retirée de l'héritage dans ce noeud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="ReuseRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la réutilisation.</xsd:documentation> + <xsd:documentation>Chaque règle a une startDate et un Identifiant de règle de référence pour la durée. + Si aucune règle n'est spécifiée et que la date actuelle est dans la StarDate, la réponse de restriction est "Aucune restriction". + Si la date est vide, la réponse de restriction est "Restreint" car il n'y a aucun moyen de calculer la date de fin. + Si une règle et une date sont précisées, alors la règle est valable (restriction appliquée).</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:sequence minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de réutilisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de départ de calcul de la règle de réutilisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>L'identifiant de la règle spécifiée pourra être retirée de l'héritage dans ce noeud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + </xsd:complexType> + + <xsd:complexType name="ClassificationRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la classification.</xsd:documentation> + <xsd:documentation>Chaque règle a une startDate et un Identifiant de règle de référence pour la durée. + Si aucune règle n'est spécifiée et que la date actuelle est dans la StarDate, la réponse de restriction est "Aucune restriction". + Si la date est vide, la réponse de restriction est "Restreint" car il n'y a aucun moyen de calculer la date de fin. + Si une règle et une date sont précisées, alors la règle est valable (restriction appliquée).</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:sequence minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de départ de calcul de la règle de classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:element name="ClassificationAudience" type="NonEmptyTokenType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Permet de gérer les questions de "diffusion restreinte", de "spécial France" et de "Confidentiel Industrie".</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>L'identifiant de la règle spécifiée pourra être retirée de l'héritage dans ce noeud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + <xsd:element name="ClassificationLevel" type="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Référence au niveau de classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ClassificationOwner" type="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Propriétaire de la classification. Service émetteur au sens de l’IGI 1300.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ClassificationReassessingDate" type="xsd:date" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de réévaluation de la classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="NeedReassessingAuthorization" type="xsd:boolean" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique si une autorisation humaine est nécessaire pour réévaluer la classification.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <xsd:simpleType name="FinalActionStorageCodeType"> + <xsd:annotation> + <xsd:documentation>Code correspondant à l’action à entreprendre au terme de la durée d’utilité courante.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"> + <xsd:enumeration value="RestrictAccess"/> + <xsd:enumeration value="Transfer"/> + <xsd:enumeration value="Copy"/> + </xsd:restriction> + </xsd:simpleType> + + <xsd:complexType name="StorageRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la durée d'utilité courante.</xsd:documentation> + <xsd:documentation>Chaque règle a une startDate et un Identifiant de règle de référence pour la durée. + Si aucune règle n'est spécifiée et que la date actuelle est dans la StarDate, la réponse de restriction est "Aucune restriction". + Si la date est vide, la réponse de restriction est "Restreint" car il n'y a aucun moyen de calculer la date de fin. + Si une règle et une date sont précisées, alors la règle est valable (restriction appliquée).</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:sequence minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de durée d'utilité courante.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de départ de calcul de la règle d'utilité courante.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>L'identifiant de la règle spécifiée pourra être retirée de l'héritage dans ce noeud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + <xsd:element name="FinalAction" type="FinalActionStorageCodeType"> + <xsd:annotation> + <xsd:documentation>Action à mettre en œuvre au terme de la durée de gestion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <xsd:simpleType name="FinalActionAppraisalCodeType"> + <xsd:annotation> + <xsd:documentation>Code correspondant à l’action à entreprendre au terme de la durée d’utilité administrative.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"> + <xsd:enumeration value="Keep"/> + <xsd:enumeration value="Destroy"/> + </xsd:restriction> + </xsd:simpleType> + + <xsd:complexType name="AppraisalRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la durée d'utilité administrative.</xsd:documentation> + <xsd:documentation>Chaque règle a une startDate et un Identifiant de règle de référence pour la durée. + Si aucune règle n'est spécifiée et que la date actuelle est dans la StarDate, la réponse de restriction est "Aucune restriction". + Si la date est vide, la réponse de restriction est "Restreint" car il n'y a aucun moyen de calculer la date de fin. + Si une règle et une date sont précisées, alors la règle est valable (restriction appliquée).</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:sequence minOccurs="0" maxOccurs="unbounded"> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de durée d'utilité administrative.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de départ de calcul de durée d'utilité administrative.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>L'identifiant de la règle spécifiée pourra être retirée de l'héritage dans ce noeud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + <xsd:element name="FinalAction" type="FinalActionAppraisalCodeType"> + <xsd:annotation> + <xsd:documentation>Action à mettre en œuvre au terme de la durée de gestion.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <!-- Gestion des règles de gel des ArchiveUnit --> + <xsd:complexType name="HoldRuleType"> + <xsd:annotation> + <xsd:documentation>Gestion de la durée de gel des ArchiveUnits.</xsd:documentation> + <xsd:documentation>Chaque règle possède un Identifiant de règle de gel de référence, ainsi qu'un ensemble + d'attributs optionnels.</xsd:documentation> + <xsd:documentation>La date de fin de gel est calculée à partir d'une date de début de restriction + (StardDate) et de la durée de validité de la règle de réference. Elle peut également être explicitement + spécifiée (HoldEndDate) si la règle de référence ne spécifie pas de durée déterminée.</xsd:documentation> + <xsd:documentation>Si la règle ne possède pas de durée de fin (calculée ou explicite), alors la règle est + réputée à durée indéterminée (restriction toujours effective)</xsd:documentation> + <xsd:documentation>La liste d'identifiants de règles à appliquer et à ignorer qui doit être appliquée à partir de cet ArchiveUnit.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="HoldRuleDefGroup" minOccurs="0" maxOccurs="unbounded" /> + <xsd:choice minOccurs="0"> + <xsd:group ref="PreventInheritanceGroup"/> + <xsd:element name="RefNonRuleId" type="RuleIdType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>L'identifiant de la règle spécifiée pourra être retirée de l'héritage dans ce noeud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + </xsd:complexType> + + <xsd:group name="HoldRuleDefGroup"> + <xsd:sequence> + <xsd:element name="Rule" type="RuleIdType"> + <xsd:annotation> + <xsd:documentation>Référence à la règle de gel.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de début de gel.</xsd:documentation> + <xsd:documentation>Si la date de début de gel est renseignée, et que la règle de référence + spécifie une durée de validité non nulle, alors la date de fin de gel est automatiquement + calculée par Vitam.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="HoldEndDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de fin de gel explicite.</xsd:documentation> + <xsd:documentation>Dans le cas où la règle de référence ne spécifie pas de durée de validité, la + règle peut alors spécifier une date de fin de gel explicite (HoldEndDate).</xsd:documentation> + <xsd:documentation>Dans le cas où la règle de référence spécifie une durée de validité, la date + de fin de gel est calculée par Vitam et ne peut être explicitement spécifiée (HoldEndDate prohibé).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="HoldOwner" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Propriétaire de la demande de gel.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="HoldReassessingDate" type="xsd:date" nillable="true" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de réévaluation du gel.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="HoldReason" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Motif de gel.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="PreventRearrangement" type="xsd:boolean" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Blocage de la reclassification de l'ArchiveUnit lorsque la restriction de gel est effective</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> +</xsd:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/seda-2.2-ontology.xsd b/webroot/xmlSchemas/seda_v2-2/seda-2.2-ontology.xsd new file mode 100644 index 0000000000000000000000000000000000000000..a571fb38c30f6988642efa42596ee5db6e67f887 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/seda-2.2-ontology.xsd @@ -0,0 +1,1062 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" + xmlns:pr="info:lc/xmlns/premis-v2" xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" elementFormDefault="qualified" + attributeFormDefault="unqualified" version="1.0"> + <xsd:include schemaLocation="seda-2.2-types.xsd"/> + + <xsd:group name="ObjectGroup"> + <xsd:annotation> + <xsd:documentation>Contient les éléments nécessaires à + la description de l'ArchiveUnit et est sensé être la racine du bloc des métadonnées de + description.</xsd:documentation> + <xsd:documentation>Chaque sous-type ou sous-groupe peut aussi être utilisé pour + construire de nouveaux types ou groupes.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="BaseObjectGroup"/> + <xsd:element ref="ObjectGroupExtenstionAbstract" minOccurs="0" maxOccurs="unbounded"/> + </xsd:sequence> + </xsd:group> + + <xsd:group name="BaseObjectGroup"> + <xsd:sequence> + <xsd:group ref="LevelGroup"/> + <xsd:group ref="TitleGroup"/> + <xsd:group ref="IdentifierGroup"/> + <xsd:group ref="DescriptionGroup"/> + <xsd:group ref="CustodialHistoryGroup"/> + <xsd:group ref="TypeGroup"/> + <xsd:group ref="DocumentTypeGroup"/> + <xsd:group ref="LanguageGroup"/> + <xsd:group ref="StatusGroup"/> + <xsd:group ref="VersionGroup"/> + <xsd:group ref="KeywordsGroup"/> + <xsd:group ref="CoverageGroup"/> + <xsd:group ref="OriginatingAgencyGroup"/> + <xsd:group ref="SubmissionAgencyGroup"/> + <xsd:group ref="AgentGroup"/> + <xsd:group ref="AuthorizedAgentGroup"/> + <xsd:group ref="WritingGroup"/> + <xsd:group ref="AudienceGroup"/> + <xsd:group ref="SourceGroup"/> + <xsd:group ref="RelationGroup"/> + <xsd:group ref="DateGroup"/> + <xsd:group ref="EventGroup"/> + <xsd:group ref="SignatureGroup"/> + <xsd:group ref="GpsGroup"/> + <xsd:group ref="OriginatingSystemIdReplyToGroup"/> + <xsd:group ref="TextContentGroup"/> + </xsd:sequence> + </xsd:group> + + <!-- Level description --> + <xsd:group name="LevelGroup"> + <xsd:sequence> + <xsd:element name="DescriptionLevel" type="LevelType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Niveau de description au sens de la norme ISAD (G). Indique si l’ArchiveUnit correspond à un fonds, + à un sous-fonds, à une classe, à une série organique, à une sous-série organique, à un dossier, à un sous-dossier ou à une pièce.</xsd:documentation> + <xsd:documentation>Référence : seda.DescriptionLevel</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="LevelType"> + <xsd:annotation> + <xsd:documentation>Valeurs de DescriptionLevel.</xsd:documentation> + <xsd:documentation>Références : descriptionlevel_code SEDA 1.0</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:token"> + <xsd:enumeration value="Fonds"/> + <xsd:enumeration value="Subfonds"/> + <xsd:enumeration value="Class"/> + <xsd:enumeration value="Collection"/> + <xsd:enumeration value="Series"/> + <xsd:enumeration value="Subseries"/> + <xsd:enumeration value="RecordGrp"/> + <xsd:enumeration value="SubGrp"/> + <xsd:enumeration value="File"/> + <xsd:enumeration value="Item"/> + <xsd:enumeration value="OtherLevel"/> + </xsd:restriction> + </xsd:simpleType> + <!-- Title description --> + <xsd:group name="TitleGroup"> + <xsd:sequence> + <xsd:element name="Title" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Intitulé de l'ArchiveUnit.</xsd:documentation> + <xsd:documentation>Références : DC.Title ead.unittitle</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Identification description --> + <xsd:group name="IdentifierGroup"> + <xsd:sequence> + <xsd:element name="FilePlanPosition" type="NonEmptyTokenType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Position de l’ArchiveUnit dans le plan de classement du service producteur.</xsd:documentation> + <xsd:documentation>Références : seda.FilePlanPosition</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="SystemId" type="NonEmptyTokenType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant attribué aux objets. Il est attribué par le SAE et correspond à un identifiant interne.</xsd:documentation> + <xsd:documentation>Références : ARMS</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingSystemId" type="NonEmptyTokenType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant système attribué à l’ArchiveUnit par l’application du service producteur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ArchivalAgencyArchiveUnitIdentifier" type="NonEmptyTokenType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant métier attribué à l'ArchiveUnit par le service d'archives. Peut être comparé à une cote.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OriginatingAgencyArchiveUnitIdentifier" type="NonEmptyTokenType" + minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant métier attribué à l’ArchiveUnit par le service producteur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransferringAgencyArchiveUnitIdentifier" type="NonEmptyTokenType" + minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant attribué à l'ArchiveUnit par le service versant.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- General description --> + <xsd:group name="DescriptionGroup"> + <xsd:sequence> + <xsd:element name="Description" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Description détaillée de l’ArchiveUnit. Correspond à la présentation du contenu au sens de la norme ISAD(G).</xsd:documentation> + <xsd:documentation>Références : DC:Documentation</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- CustodialHistory type --> + <xsd:group name="CustodialHistoryGroup"> + <xsd:sequence> + <xsd:element name="CustodialHistory" type="CustodialHistoryType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Énumère les changements successifs de propriété, de responsabilité et de conservation des ArchiveUnit avant + leur entrée dans le lieu de conservation. On peut notamment y indiquer comment s'est effectué le passage de l'application + d'origine au fichier archivable. Correspond à l'historique de la conservation en ISAD(G).</xsd:documentation> + <xsd:documentation>Références : seda.CustodialHistory</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="CustodialHistoryType"> + <xsd:sequence> + <xsd:element name="CustodialHistoryItem" type="CustodialHistoryItemType" minOccurs="1" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Description d'une période ou d'un événement précis dans l'historique.</xsd:documentation> + <xsd:documentation>Références : seda.CustodialHistoryItem</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="CustodialHistoryFile" type="DataObjectRefType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Référence à un fichier de journalisation externe.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="CustodialHistoryItemType"> + <xsd:complexContent> + <xsd:extension base="TextType"> + <xsd:attribute name="when" type="DateType" use="optional"/> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- OAIS type description --> + <xsd:group name="TypeGroup"> + <xsd:sequence> + <xsd:element name="Type" type="TextType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Type d’information au sens de l’OAIS (information de représentation, information de pérennisation, etc.).</xsd:documentation> + <xsd:documentation>Références : seda.DocumentType</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Document type description --> + <xsd:group name="DocumentTypeGroup"> + <xsd:sequence> + <xsd:element name="DocumentType" type="TextType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Type de document au sens diplomatique du terme (ex. compte-rendu de réunion, note, correspondance, etc.). Ne pas confondre avec Type.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Language description --> + <xsd:group name="LanguageGroup"> + <xsd:sequence> + <xsd:element name="Language" type="xsd:language" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Langue du contenu des objets-données.</xsd:documentation> + <xsd:documentation>Références : seda.Language</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DescriptionLanguage" type="xsd:language" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Langue utilisée pour les informations de représentation et de pérennisation.</xsd:documentation> + <xsd:documentation>Références : seda.DescriptionLanguage</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Status description --> + <xsd:group name="StatusGroup"> + <xsd:sequence> + <xsd:element name="Status" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Etat de l'objet-données (par rapport avec son cycle de vie). Permet par exemple d'indiquer si la signature du fichier a été vérifiée avant le transfert aux archives.</xsd:documentation> + <xsd:documentation>Références : seda.Status</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Version description --> + <xsd:group name="VersionGroup"> + <xsd:sequence> + <xsd:element name="Version" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Permet d'indiquer quelle est la version du document.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Keywords description --> + <xsd:group name="KeywordsGroup"> + <xsd:sequence> + <xsd:element name="Tag" type="NonEmptyTokenType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Mots-clés ou liste de mots-clés génériques. En ce qui concerne l'indexation, on pourra utiliser Tag ou Keyword en fonction de ce que l'on souhaite décrire.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Keyword" type="KeywordsType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Mots-clef avec contexte inspiré du SEDA 1.0. En ce qui concerne l'indexation, on pourra utiliser Tag ou Keyword en fonction de ce que l'on souhaite décrire.</xsd:documentation> + <xsd:documentation>Références : seda.Keyword</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <!-- Repris du SEDA 1.0 --> + <xsd:complexType name="KeywordsType"> + <xsd:annotation> + <xsd:documentation>Mots-clés.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="KeywordContent" type="TextType"> + <xsd:annotation> + <xsd:documentation>Valeur du mot-clé. A utiliser avec Keyword.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="KeywordReference" type="IdentifierType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Identifiant du mot clé dans un référentiel donné. Par exemple, pour un lieu, il pourrait s'agir de son code officiel géographique selon l'INSEE.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="KeywordType" type="KeyType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Type de mot clé.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:attribute name="id" type="xsd:ID" use="optional"/> + </xsd:complexType> + <xsd:complexType name="KeyType"> + <xsd:simpleContent> + <xsd:extension base="CodeKeywordType"> + <xsd:attribute name="listVersionID" type="xsd:token" use="optional" + default="edition 2009"> + </xsd:attribute> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + <!-- =============================================================== --> + <!-- ===== Code List KeywordType: KeywordType Code ======= --> + <!-- =============================================================== --> + <xsd:simpleType name="CodeKeywordType"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Table des types de mots-clés.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:token"> + <xsd:enumeration value="corpname"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Collectivité.</xsd:documentation> + <xsd:documentation>Références : ead.corpname</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="famname"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Nom de famille.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="geogname"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Nom géographique.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="name"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Nom.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="occupation"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Fonction.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="persname"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Nom de personne.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="subject"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Mot-matière.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="genreform"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Type de document.</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + <xsd:enumeration value="function"> + <xsd:annotation> + <xsd:documentation xml:lang="fr">Activité.</xsd:documentation> + <xsd:documentation xml:lang="fr">Références : ead.function</xsd:documentation> + </xsd:annotation> + </xsd:enumeration> + </xsd:restriction> + </xsd:simpleType> + + <!-- Coverage description --> + <xsd:group name="CoverageGroup"> + <xsd:sequence> + <xsd:element name="Coverage" type="CoverageType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Couverture spatiale, temporelle ou juridictionnelle de l’ArchiveUnit</xsd:documentation> + <xsd:documentation>Références : DC.Coverage</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="CoverageType"> + <xsd:sequence> + <xsd:element name="Spatial" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Couverture spatiale ou couverture géographique.</xsd:documentation> + <xsd:documentation>Références: AGKRMS.spatialCoverage</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Temporal" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Couverture temporelle.</xsd:documentation> + <xsd:documentation>Références: AGKRMS.temporalCoverage</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Juridictional" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Juridiction administrative ou ressort administratif.</xsd:documentation> + <xsd:documentation>Références: AGKRMS.juridictionalCoverage</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <!-- OriginatingAgency description --> + <xsd:group name="OriginatingAgencyGroup"> + <xsd:sequence> + <xsd:element name="OriginatingAgency" type="OrganizationType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Service producteur. "Personne physique ou morale, publique ou privée, qui a produit, reçu et conservé des archives dans l'exercice de son activité", Dictionnaire de terminologie archivistique, direction des archives de France, 2002.</xsd:documentation> + <xsd:documentation>Références : seda.OriginatingAgency</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- SubmissionAgency description --> + <xsd:group name="SubmissionAgencyGroup"> + <xsd:sequence> + <xsd:element name="SubmissionAgency" type="OrganizationType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Service versant responsable du transfert des données.</xsd:documentation> + <xsd:documentation>Références : seda.SubmissionAgency</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Proxy description --> + <xsd:group name="AuthorizedAgentGroup"> + <xsd:sequence> + <xsd:element name="AuthorizedAgent" type="AgentType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Titulaire des droits de propriété intellectuelle.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Writing description --> + <xsd:group name="WritingGroup"> + <xsd:sequence> + <xsd:annotation> + <xsd:documentation>Rédacteur de l'objet d'archive.</xsd:documentation> + </xsd:annotation> + <xsd:element name="Writer" type="AgentType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Rédacteur Rédacteur de l’ArchiveUnit.</xsd:documentation> + <xsd:documentation>Références : interpares.Writer</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Audience description --> + <xsd:group name="AudienceGroup"> + <xsd:sequence> + <xsd:annotation> + <xsd:documentation>Audience du document.</xsd:documentation> + </xsd:annotation> + <xsd:group ref="AddresseeGroup"/> + <xsd:group ref="RecipientGroup"/> + <xsd:group ref="TransmitterGroup"/> + <xsd:group ref="SenderGroup"/> + </xsd:sequence> + </xsd:group> + + <!-- Source description --> + <xsd:group name="SourceGroup"> + <xsd:sequence> + <xsd:element name="Source" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En cas de substitution numérique, permet de faire référence au papier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Relation description --> + <xsd:group name="RelationGroup"> + <xsd:annotation> + <xsd:documentation>Les valeurs sont des identifiants au choix : - d'un autre objet données (DataObjectRefIdType ou GroupIdType s'ils sont dans le même transfert, ou identifiant dans le SAE sinon) - d'un autre ArchiveUnit (ArchiveUnitRefIdType s'il est dans le même transfert, ou identifiant dans le SAE sinon).</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="RelatedObjectReference" type="RelatedObjectReferenceType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Référence à un objet faisant ou ne faisant pas partie du présent paquet d'information.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="RelatedObjectReferenceType"> + <xsd:sequence> + <xsd:element name="IsVersionOf" type="DataObjectOrArchiveUnitReferenceType" + minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Est une version de. Edition, adaptation, traduction. Cette relation permet d'indiquer les modifications dans le contenu.</xsd:documentation> + <xsd:documentation>Références : DC.Relation.isVersionOf</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Replaces" type="DataObjectOrArchiveUnitReferenceType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Remplace. Cette relation permet d'indiquer les objets remplacés par le niveau courant de description.</xsd:documentation> + <xsd:documentation>DC.Relation.replaces</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Requires" type="DataObjectOrArchiveUnitReferenceType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Requiert. Cette relation permet d'indiquer les objets nécessaire à la compréhension du niveau courant de description.</xsd:documentation> + <xsd:documentation>Références : DC.Relation.requires</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="IsPartOf" type="DataObjectOrArchiveUnitReferenceType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Est une partie de. Cette relation permet d'indique qu'un objet est une partie d'un autre.</xsd:documentation> + <xsd:documentation>Références : DC.Relation.isPartOf</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="References" type="DataObjectOrArchiveUnitReferenceType" minOccurs="0" + maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Référence. Cette relation permet d'indiquer qu'un objet en référence un autre.</xsd:documentation> + <xsd:documentation>DC.Relation.references</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="DataObjectOrArchiveUnitReferenceType"> + <xsd:choice> + <xsd:element name="ArchiveUnitRefId" type="ArchiveUnitRefIdType"> + <xsd:annotation> + <xsd:documentation>Référence à un ArchiveUnit interne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectReference" type="DataObjectRefType"> + <xsd:annotation> + <xsd:documentation>Référence à un objet-données ou à un groupe d'objets-données interne(s).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="RepositoryArchiveUnitPID" type="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Référence à un ArchiveUnit déjà conservé dans un système d'archivage.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="RepositoryObjectPID" type="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Référence à un un objet-données ou à un groupe d'objets-données déjà conservé(s) dans un système d'archivage.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ExternalReference" type="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Référence externe.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:complexType> + <!-- Date description --> + <xsd:group name="DateGroup"> + <xsd:sequence> + <xsd:element name="CreatedDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de création.</xsd:documentation> + <xsd:documentation>Références : ARKMS.DateCreated</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="TransactedDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de la transaction.</xsd:documentation> + <xsd:documentation>Références : ARKMS.DateTransacted</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="AcquiredDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de numérisation.</xsd:documentation> + <xsd:documentation>Références : ARKMS.DateAcquired</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="SentDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date d'envoi.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ReceivedDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de réception.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="RegisteredDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date d'enregistrement.</xsd:documentation> + <xsd:documentation>Références : ARMS.DateDeclared</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="StartDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date d'ouverture / date de début.</xsd:documentation> + <xsd:documentation>Références : AGKRMS.StartDate</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="EndDate" type="DateType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de fermeture / Date de fin.</xsd:documentation> + <xsd:documentation>Références : AGKRMS.EndDate</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DateLitteral" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Champ date en texte libre.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="DateType"> + <xsd:union memberTypes="xsd:date xsd:dateTime xsd:gYear xsd:gYearMonth xsd:gMonth xsd:gMonthDay xsd:gDay"/> + </xsd:simpleType> + <!-- Event description --> + <xsd:group name="EventGroup"> + <xsd:sequence> + <xsd:element name="Event" type="EventType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Informations décrivant un événement survenu au cours d’une procédure (ex. publication d’un marché, notification d’un marché, recueil d’un avis administratif, etc.).</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="EventType"> + <xsd:sequence> + <xsd:element name="EventIdentifier" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'événement.</xsd:documentation> + <xsd:documentation>Références : premis.eventIdentifier</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="EventTypeCode" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Code du type d'événement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="EventType" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Type d'événement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="EventDateTime" type="DateType"> + <xsd:annotation> + <xsd:documentation>Date et heure de l'événement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="EventDetail" type="TextType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Détail sur l'événement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Outcome" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Résultat du traitement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OutcomeDetail" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Détail sur le résultat du traitement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OutcomeDetailMessage" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Message détaillé sur le résultat du traitement.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="EventDetailData" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Message technique détaillant l'erreur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="LinkingAgentIdentifier" type="LinkingAgentIdentifierType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Permet de renseigner des agents répertoriés dans des évènements.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element ref="EventAbstract" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Permet d'étendre de nouveaux types d'évenéments.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="LinkingAgentIdentifierType"> + <xsd:sequence> + <xsd:element name="LinkingAgentIdentifierType" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant d'un agent répertorié dans des évènements.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="LinkingAgentIdentifierValue" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Mention d'un agent répertorié dans des évènements.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="LinkingAgentRole" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Fonction d'un agent répertorié dans des évènements.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <!-- Signature description --> + <xsd:group name="SignatureGroup"> + <xsd:sequence> + <xsd:element name="Signature" type="SignatureType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Contient toutes les informations relatives à la signature.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="SignatureType"> + <xsd:sequence> + <xsd:element name="Signer" type="SignerType" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Signataire(s) de la transaction ou de l'objet.</xsd:documentation> + <xsd:documentation>Références : premis.signer</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Validator" type="ValidatorType"> + <xsd:annotation> + <xsd:documentation>Validateur de la signature.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Masterdata" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Référentiel des personnes et des organisations au moment de la vérification de la signature et de sa validation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="ReferencedObject" type="ReferencedObjectType"> + <xsd:annotation> + <xsd:documentation>Référence à l'objet signé.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="SignerType"> + <xsd:group ref="SignerGroup"/> + </xsd:complexType> + <xsd:complexType name="ValidatorType"> + <xsd:group ref="ValidatorGroup"/> + </xsd:complexType> + <xsd:complexType name="ReferencedObjectType"> + <xsd:annotation> + <xsd:documentation>Contient la référence à l'objet signé (et son empreinte jusqu'à la fin de la phase de versement dans le SAE).</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="SignedObjectId" type="DataObjectRefIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'objet-données signé.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="SignedObjectDigest" type="MessageDigestBinaryObjectType"> + <xsd:annotation> + <xsd:documentation>Empreinte obligatoire jusqu'au processus de versement pour assurer la portabilité de la valeur probante. Le SAE peut ne pas la conserver si l'on considère que l'identifiant de l'objet correspondant suffit. Ce procédé permet de résister au temps lorsque les informations binaires du paquet seront converties au gré des opérations de préservation de la lisibilité des formats. Au cours de ces opérations, l'identifiant ne changera pas, contrairement au format dufichier et donc à son empreinte.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <xsd:group name="SignerGroup"> + <xsd:sequence> + <xsd:group ref="PersonOrEntityGroup"/> + <xsd:element name="SigningTime" type="xsd:dateTime"> + <xsd:annotation> + <xsd:documentation>Date de signature.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:group ref="BusinessGroup"/> + </xsd:sequence> + </xsd:group> + <xsd:group name="ValidatorGroup"> + <xsd:sequence> + <xsd:group ref="PersonOrEntityGroup"/> + <xsd:element name="ValidationTime" type="xsd:dateTime"> + <xsd:annotation> + <xsd:documentation>Date de la validation de la signature.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:group ref="BusinessGroup"/> + </xsd:sequence> + </xsd:group> + + <!-- Addressee description --> + <xsd:group name="AddresseeGroup"> + <xsd:sequence> + <xsd:element name="Addressee" minOccurs="0" maxOccurs="unbounded" type="AgentType"> + <xsd:annotation> + <xsd:documentation>Destinataire pour action. Utilisé pour indiquer le nom du destinatire par exemple dans un courrier électronique.</xsd:documentation> + <xsd:documentation>Références : ARMS.Addressee, Interpares.Addressee</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <!-- Recipient description --> + <xsd:group name="RecipientGroup"> + <xsd:sequence> + <xsd:element name="Recipient" minOccurs="0" maxOccurs="unbounded" type="AgentType"> + <xsd:annotation> + <xsd:documentation>Destinataire pour information. Utilisé pour indiquer le nom du destinatire en copie, pour information, par exemple dans un courrier électronique.</xsd:documentation> + <xsd:documentation>Références : Interpares.Recipient</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <!-- Transmitter description --> + <xsd:group name="TransmitterGroup"> + <xsd:sequence> + <xsd:element name="Transmitter" type="AgentType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Emetteur du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <!-- Sender description --> + <xsd:group name="SenderGroup"> + <xsd:sequence> + <xsd:element name="Sender" type="AgentType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Expéditeur du message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Pour ajouter des agents génériques --> + <xsd:group name="AgentGroup"> + <xsd:sequence> + <xsd:element name="Agent" type="AgentType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Agent générique.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <!-- Agent description --> + <xsd:complexType name="AgentType"> + <xsd:annotation> + <xsd:documentation>Informations décrivant une personne physique ou morale.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="PersonOrEntityGroup"/> + <xsd:group ref="BusinessGroup"/> + </xsd:sequence> + </xsd:complexType> + + <!-- Person or Entity description --> + <xsd:group name="PersonOrEntityGroup"> + <xsd:sequence> + <xsd:choice> + <xsd:sequence> + <xsd:element name="FirstName" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Prénom d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="BirthName" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Nom de naissance d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="FullName" type="xsd:string" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Nom complet d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GivenName" type="xsd:string" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Nom d'usage d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Gender" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Sexe de la personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="BirthDate" type="xsd:date" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de naissance de la personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="BirthPlace" type="BirthOrDeathPlaceType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Lieu de naissance de la personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DeathDate" type="xsd:date" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de décès d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DeathPlace" type="BirthOrDeathPlaceType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Lieu de décès d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Nationality" minOccurs="0" maxOccurs="unbounded" type="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Nationalité d'une personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:sequence> + <xsd:element name="Corpname" type="xsd:string"> + <xsd:annotation> + <xsd:documentation>Nom d'une entité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:choice> + <xsd:element name="Identifier" type="NonEmptyTokenType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Identifiant de la personne (par exemple, le numéro matricule) ou de l'entité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="BirthOrDeathPlaceType"> + <xsd:group ref="LocationGroup"/> + </xsd:complexType> + <!-- Business description --> + <xsd:group name="BusinessGroup"> + <xsd:annotation> + <xsd:documentation>Références : AGKRMS.Business</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="Function" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Fonction.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Activity" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Activité.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Position" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Intitulé du poste de travail occupé par la personne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Role" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Droits avec lesquels un utilisateur a réalisé une opération, notamment dans une application.</xsd:documentation> + <xsd:documentation>Références : moreq.role</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Mandate" type="TextType" minOccurs="0" maxOccurs="unbounded"> + <xsd:annotation> + <xsd:documentation>Définit la propriété intellectuelle et artistique.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <!-- Location description --> + <xsd:group name="LocationGroup"> + <xsd:annotation> + <xsd:documentation>Localisation.</xsd:documentation> + </xsd:annotation> + <xsd:all> + <xsd:element name="Geogname" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Nom géographique.</xsd:documentation> + <xsd:documentation>Références : ead.geogname</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Address" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Adresse.</xsd:documentation> + <xsd:documentation>Références : ead.address</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="PostalCode" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Code postal.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="City" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Ville.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Region" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Région.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Country" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>En plus des balises Tag et Keyword, il est possible d'indexer les objets avec des éléments pré-définis : Pays.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:all> + </xsd:group> + <!-- GPS Description: shared with Descriptive and Technical --> + <xsd:group name="GpsGroup"> + <xsd:sequence> + <xsd:element name="Gps" type="GpsType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Coordonnées gps complétées ou vérifiées par un utilisateur. Fait référence à des coordonnées traitées par un utilisateur et non à des coordonnées captées.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="GpsType"> + <xsd:sequence> + <xsd:element name="GpsVersionID" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant de la version du GPS.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsAltitude" type="xsd:integer" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique l'altitude basée sur la référence dans GPSAltitudeRef. L'altitude est exprimée en mètres.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsAltitudeRef" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique l'altitude utilisée comme altitude de référence.</xsd:documentation> + <xsd:documentation>Si l'altitude est au dessus du niveau de la mer, la valeur 0 est normalement donnée.</xsd:documentation> + <xsd:documentation>Si l'altitude est au-dessous du niveau de la mer, la veleur 1 est normalement donnée.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsLatitude" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>La latitude peut être exprimée de deux manières différentes : 1)degrés, décimaux ou 2)degrés, minutes et secondes.</xsd:documentation> + <xsd:documentation>1)Si la latitude est exprimée en degrés, décimaux, le format type est dd, dd. Par ex: "45.3130339".</xsd:documentation> + <xsd:documentation>2)Si la latitude est exprimée en degrés, minutes et secondes, le format type est dd, mm, ss. Par ex: "45 18 46.922".</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsLatitudeRef" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique si la latitude est nord ou sud. La valeur 'N' indique la latitude nord, et 'S' indique la latitude sud.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsLongitude" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>La longitude peut être exprimée de deux manières différentes : 1)degrés, décimaux ou 2)degrés, minutes et secondes.</xsd:documentation> + <xsd:documentation>1)Si la longitude est exprimée en degrés, décimaux, le format type est dd, dd. Par ex: "5.392285833333334".</xsd:documentation> + <xsd:documentation>2)Si la longitude est exprimée en degrés, minutes et secondes, le format type est dd, mm, ss. Par ex: "5 23 32.229".</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsLongitudeRef" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Indique si la longitude est est ou ouest. La valeur 'E' indique la longitude est, et 'W' indique la longitude Ouest.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="GpsDateStamp" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Heure et Date de la position GPS.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + <xsd:group name="OriginatingSystemIdReplyToGroup"> + <xsd:sequence> + <xsd:element name="OriginatingSystemIdReplyTo" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Référence du message auquel on répond.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:group name="TextContentGroup"> + <xsd:sequence> + <xsd:element name="TextContent" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Contenu du message électronique.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> +</xsd:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/seda-2.2-technical.xsd b/webroot/xmlSchemas/seda_v2-2/seda-2.2-technical.xsd new file mode 100644 index 0000000000000000000000000000000000000000..f3cfae5b537003ffa1515c550a885a4177560600 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/seda-2.2-technical.xsd @@ -0,0 +1,530 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" elementFormDefault="qualified" + attributeFormDefault="unqualified" version="1.0"> + <xsd:include schemaLocation="seda-2.2-types.xsd"/> + <xsd:include schemaLocation="seda-2.2-ontology.xsd"/> + <!-- + ***************************** + *** Code List + ***************************** + + --> + <xsd:group name="TechnicalCodeListsGroup"> + <xsd:annotation> + <xsd:documentation>Liste de codes à utiliser dans les métadonnées + techniques.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="DigestAlgorithmCodeListGroup"/> + <xsd:group ref="MimeTypeCodeListGroup" minOccurs="0"/> + <xsd:group ref="EncodingCodeListGroup" minOccurs="0"/> + <xsd:group ref="FileFormatCodeListGroup"/> + <xsd:group ref="CompressionAlgorithmCodeListGroup" minOccurs="0"/> + <xsd:group ref="DataObjectVersionCodeListGroup" minOccurs="0"/> + </xsd:sequence> + </xsd:group> + + <!-- Identification of format code --> + <xsd:simpleType name="MimeTypeType"> + <xsd:annotation> + <xsd:documentation>Code de type Mime.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + <xsd:group name="MimeTypeCodeListGroup"> + <xsd:sequence> + <xsd:element name="MimeTypeCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version de la liste de code du type Mime.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="EncodingType"> + <xsd:annotation> + <xsd:documentation>Encodage du fichier.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + <xsd:group name="EncodingCodeListGroup"> + <xsd:sequence> + <xsd:element name="EncodingCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version de la liste de code d'encodage du + fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="FileFormatType"> + <xsd:annotation> + <xsd:documentation>Identification du format de fichier.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + <xsd:group name="FileFormatCodeListGroup"> + <xsd:sequence> + <xsd:element name="FileFormatCodeListVersion" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version de la liste de code d'identification du format.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="CompressionAlgorithmType"> + <xsd:annotation> + <xsd:documentation>Algorithme de compression utilisée.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + <xsd:group name="CompressionAlgorithmCodeListGroup"> + <xsd:sequence> + <xsd:element name="CompressionAlgorithmCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Version de la liste de code de l'algorithme de compression.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Identification d'une version pour un même objet intellectuel --> + <xsd:group name="DataObjectVersionCodeListGroup"> + <xsd:sequence> + <xsd:element name="DataObjectVersionCodeListVersion" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Liste de codes correspondant aux diverses versions d'un objet-données au sein d’un groupe d'objets-données (ex. original papier, conservation, diffusion, vignette, txt).</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="VersionIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant utilisé pour référencer les versions (conservation, diffusion, thumbnail/vignette, raw/brut, txt, ...).</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + + <!-- Paquet d'Objets-données --> + <xsd:group name="DataObjectVersionGroup"> + <xsd:annotation> + <xsd:documentation>Groupe d’objets-données (numériques ou physiques), correspondant aux + différentes versions d’un même objet intellectuellement unique. Chaque version peut + être par exemple : original papier, version de conservation, version de diffusion, + version vignette, version texte ascii… Lorsqu'un objet-donnée fait partie d'un + groupe, le référencement dans les ArchiveUnit ne peut se faire que via ce groupe + (DataObjectGroupId).</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:choice> + <xsd:element name="DataObjectGroupReferenceId" type="GroupRefIdType"> + <xsd:annotation> + <xsd:documentation>Référence à un Identifiant du groupe d'objets-données DataObjectVersionGroup.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectGroupId" type="GroupIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant du groupe d'objets-données DataObjectVersionGroup (première et unique définition).</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + </xsd:group> + <xsd:complexType name="MinimalDataObjectType" abstract="true"> + <xsd:sequence> + <xsd:element name="DataObjectProfile" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Référence à une partie d'un profil d’archivage applicable à un objet technique en particulier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectSystemId" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant attribué aux objets de données. Il est attribué par le SAE et correspond à un identifiant interne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectGroupSystemId" type="NonEmptyTokenType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant attribué aux groupes d'objets de données. Il est attribué par le SAE et correspond à un identifiant interne.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Relationship" minOccurs="0" maxOccurs="unbounded" + type="RelationshipType"> + <xsd:annotation> + <xsd:documentation>Permet de spécifier un lien technique entre un objet-données et une signature.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:group ref="DataObjectVersionGroup" minOccurs="0"/> + <xsd:element name="DataObjectVersion" type="VersionIdType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version d’un objet-données (par exemple : original papier, conservation, diffusion, vignette, txt, …).</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + <xsd:attribute name="id" type="DataObjectIdType" use="required"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'objet-données associé.</xsd:documentation> + </xsd:annotation> + </xsd:attribute> + </xsd:complexType> + + <!-- Données liées --> + <xsd:complexType name="RelationshipType"> + <xsd:attribute name="target" type="xsd:IDREF" use="required"/> + <xsd:attribute name="type" type="NonEmptyTokenType" use="required"/> + </xsd:complexType> + + <xsd:group name="MinimalBinaryDataObjectGroup"> + <xsd:sequence> + <xsd:choice minOccurs="0" maxOccurs="1"> + <xsd:element name="Attachment" type="BinaryObjectType"> + <xsd:annotation> + <xsd:documentation>Objet-données (contenu binaire ou fichier joint).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Uri" type="xsd:anyURI"> + <xsd:annotation> + <xsd:documentation>L'URI spécifie où se trouve l'objet-données numérique. Peut correspondre à un chemin relatif.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + <xsd:element name="MessageDigest" type="MessageDigestBinaryObjectType"> + <xsd:annotation> + <xsd:documentation>Empreinte de l'objet-données.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- Contenu de données binaire --> + <xsd:complexType name="BinaryObjectType"> + <xsd:simpleContent> + <xsd:extension base="xsd:base64Binary"> + <xsd:attribute name="filename" type="xsd:string" use="optional"/> + <xsd:attribute name="uri" type="xsd:anyURI" use="optional"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + + <!-- Objet de donnees numérique --> + <xsd:complexType name="BinaryDataObjectType"> + <xsd:annotation> + <xsd:documentation>Objet-données numérique.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="MinimalDataObjectType"> + <xsd:annotation> + <xsd:documentation>Métadonnées techniques minimales : URI, Digest, Poids.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:group ref="MinimalBinaryDataObjectGroup" minOccurs="0"/> + <xsd:element name="Size" type="SizeInBytesType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Permet de spécifier la taille de l'objet-données en octet.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Compressed" type="CompressedType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Indique si l’objet-données est compressé et doit être décompressé.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:group ref="BinaryTechnicalDescriptionGroup"> + <xsd:annotation> + <xsd:documentation>Métadonnées techniques pour les objets-données numériques.</xsd:documentation> + </xsd:annotation> + </xsd:group> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + + + <xsd:complexType name="CompressedType"> + <xsd:simpleContent> + <xsd:extension base="xsd:string"> + <xsd:attribute name="algorithm" type="CompressionAlgorithmType" use="required"/> + <xsd:attribute name="uncompressedSize" type="SizeInBytesType" use="required"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + + <xsd:group name="BinaryTechnicalDescriptionGroup"> + <xsd:annotation> + <xsd:documentation>Métadonnées techniques pour les objets-données numériques.</xsd:documentation> + <xsd:documentation>Inspiré du schéma FITS.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="FormatIdentification" type="FormatIdentificationType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identification du format de l'objet-données.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="FileInfo" type="FileInfoType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Propriétés techniques génériques du fichier (nom d’origine, logiciel de création, système d’exploitation de création).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Metadata" type="CoreMetadataType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Propriétés techniques spécifiques du fichier en fonction de sa nature technique (texte, document, image, audio, vidéo, etc.).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OtherMetadata" type="DescriptiveTechnicalMetadataType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Autres métadonnées techniques si celles définies précédemment ne suffisent pas.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + + <!-- FormatIdentification elements --> + <xsd:complexType name="FormatIdentificationType"> + <xsd:sequence> + <xsd:element name="FormatLitteral" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Forme littérale du nom du format.</xsd:documentation> + <xsd:documentation>Exemple : Microsoft Word Document.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="MimeType" type="MimeTypeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Type Mime associé, potentiellement stable mais pas assez précis.</xsd:documentation> + <xsd:documentation>Exemple : application/msword</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="FormatId" type="FileFormatType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Type spécifique du format tel que défini dans FormatIdCodeList.</xsd:documentation> + <xsd:documentation>Exemple : (Pronom)fmt/40</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Encoding" type="EncodingType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Encodage du fichier tel que défini dans EncodingIdCodeList.</xsd:documentation> + <xsd:documentation>Exemple : Utf-8</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <!-- File info elements --> + <xsd:complexType name="FileInfoType"> + <xsd:annotation> + <xsd:documentation>Informations sur le fichier lui-même (d'un point de vue technique).</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="Filename" type="xsd:string"> + <xsd:annotation> + <xsd:documentation>Nom du fichier d'origine.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="CreatingApplicationName" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Nom de l'application utilisée pour créer le fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="CreatingApplicationVersion" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version de l'application utilisée pour créer le fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DateCreatedByApplication" type="xsd:dateTime" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de création du fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="CreatingOs" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Système d’exploitation utilisé pour créer le fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="CreatingOsVersion" type="xsd:string" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Version du système d'exploitation utilisé pour créer le fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="LastModified" type="xsd:dateTime" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Date de la dernière modification du fichier.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <!-- Objet de donnees physique --> + <xsd:group name="PhysicalTechnicalDescriptionGroup"> + <xsd:annotation> + <xsd:documentation>Objet-données physique.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:element name="PhysicalDimensions" type="DimensionsType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Dimensions d'un objet-données physique.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element ref="OtherDimensionsAbstract" minOccurs="0" maxOccurs="unbounded"/> + </xsd:sequence> + </xsd:group> + + <!-- Objet de donnees physique pour les messages Request --> + <xsd:complexType name="PhysicalDataObjectType"> + <xsd:complexContent> + <xsd:extension base="MinimalDataObjectType"> + <xsd:sequence> + <xsd:element name="PhysicalId" type="IdentifierType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Identifiant physique d’un objet-données physique, externe à celui-ci (ex. code-barres).</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:group ref="PhysicalTechnicalDescriptionGroup"/> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <!-- Metadata types: inspired from various Library of Congress schema --> + <xsd:complexType name="CoreMetadataType"> + <xsd:annotation> + <xsd:documentation>Métadonnées de base par type d'objet-données.</xsd:documentation> + </xsd:annotation> + <xsd:choice> + <xsd:element name="Text" type="TextTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Métadonnées pour un objet-données de type textuel.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Document" type="DocumentTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Métadonnées pour un objet-données de type document.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Image" type="ImageTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Métadonnées pour un objet-données de type image.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Audio" type="AudioTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Métadonnées pour un objet-données de type audio.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Video" type="VideoTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Métadonnées pour un objet-données de type vidéo.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element ref="OtherCoreTechnicalMetadataAbstract"> + <xsd:annotation> + <xsd:documentation>Métadonnées pour un objet-données d’un autre type (base de données, 3D, programmes, formats propriétaires, etc.).</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:complexType> + + <!-- Physical description: inspired from AudioMD of Library of Congress and UNECE_MeasurementUnitCommonCode --> + <xsd:complexType name="DimensionsType"> + <xsd:annotation> + <xsd:documentation>Permet d'exprimer les mesures de dimensions basiques.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="BaseDimensionsType"> + <xsd:sequence> + <xsd:element name="Width" type="MeasurementType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : largeur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Height" type="MeasurementType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : hauteur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Depth" type="MeasurementType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : profondeur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Shape" type="xsd:string" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : forme.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Diameter" type="MeasurementType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : diamètre.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Length" type="MeasurementType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : longueur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Thickness" type="MeasurementType" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : épaisseur.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="Weight" type="MeasurementWeightType" minOccurs="0" + maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : poids.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="NumberOfPage" type="xsd:int" minOccurs="0" maxOccurs="1"> + <xsd:annotation> + <xsd:documentation>Métadonnée de dimension physique : nombre de pages.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + <xsd:complexType name="BaseDimensionsType" abstract="true"/> + <xsd:complexType name="MeasurementType"> + <xsd:simpleContent> + <xsd:extension base="xsd:decimal"> + <xsd:attribute name="unit" type="MeasurementUnitsType" use="required"> + <xsd:annotation> + <xsd:documentation>Références : Voir UNECE_MeasurementUnitCommonCode_8.xsd</xsd:documentation> + </xsd:annotation> + </xsd:attribute> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + <xsd:simpleType name="MeasurementUnitsType"> + <xsd:restriction base="xsd:string"> + <xsd:enumeration value="micrometre"/> + <xsd:enumeration value="4H"/> + <xsd:enumeration value="millimetre"/> + <xsd:enumeration value="MMT"/> + <xsd:enumeration value="centimetre"/> + <xsd:enumeration value="CMT"/> + <xsd:enumeration value="metre"/> + <xsd:enumeration value="inch"/> + <xsd:enumeration value="INH"/> + <xsd:enumeration value="foot"/> + <xsd:enumeration value="FOT"/> + </xsd:restriction> + </xsd:simpleType> + <xsd:complexType name="MeasurementWeightType"> + <xsd:simpleContent> + <xsd:extension base="xsd:decimal"> + <xsd:attribute name="unit" type="MeasurementWeightUnitsType" use="required"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + <xsd:simpleType name="MeasurementWeightUnitsType"> + <xsd:restriction base="xsd:string"> + <xsd:enumeration value="microgram"/> + <xsd:enumeration value="MC"/> + <xsd:enumeration value="milligram"/> + <xsd:enumeration value="MGM"/> + <xsd:enumeration value="gram"/> + <xsd:enumeration value="GRM"/> + <xsd:enumeration value="kilogram"/> + <xsd:enumeration value="KGM"/> + </xsd:restriction> + </xsd:simpleType> + +</xsd:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/seda-2.2-types.xsd b/webroot/xmlSchemas/seda_v2-2/seda-2.2-types.xsd new file mode 100644 index 0000000000000000000000000000000000000000..acb10fdf905085e7d1a701d9ec4f97ae531f4b78 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/seda-2.2-types.xsd @@ -0,0 +1,341 @@ +<?xml version="1.0" encoding="UTF-8"?> +<xsd:schema + targetNamespace="fr:gouv:culture:archivesdefrance:seda:v2.2" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns="fr:gouv:culture:archivesdefrance:seda:v2.2" + elementFormDefault="qualified" + attributeFormDefault="unqualified" + version="1.0"> + <xsd:include schemaLocation="seda-2.2-ontology.xsd"/> + + <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/> + <xsd:import namespace="http://www.w3.org/1999/xlink" schemaLocation="xlink.xsd"/> + + <!-- + ***************************** + *** Types de base + ***************************** + --> + <!-- Code --> + <xsd:complexType name="CodeType"> + <xsd:simpleContent> + <xsd:extension base="NonEmptyTokenType"> + <xsd:attribute name="listID" type="xsd:token" use="optional"/> + <xsd:attribute name="listAgencyID" type="xsd:token" use="optional"/> + <xsd:attribute name="listAgencyName" type="xsd:string" use="optional"/> + <xsd:attribute name="listName" type="xsd:string" use="optional"/> + <xsd:attribute name="listVersionID" type="xsd:token" use="optional"/> + <xsd:attribute name="name" type="xsd:string" use="optional"/> + <xsd:attribute name="languageID" type="xsd:language" use="optional"/> + <xsd:attribute name="listURI" type="xsd:anyURI" use="optional"/> + <xsd:attribute name="listSchemeURI" type="xsd:anyURI" use="optional"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + + <!-- Texte --> + <xsd:complexType name="TextType"> + <xsd:simpleContent> + <xsd:extension base="xsd:string"> + <xsd:attribute ref="xml:lang" use="optional"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + + <!-- Identifiant --> + <xsd:complexType name="IdentifierType"> + <xsd:simpleContent> + <xsd:extension base="NonEmptyTokenType"> + <xsd:attribute name="schemeID" type="xsd:token" use="optional"/> + <xsd:attribute name="schemeName" type="xsd:string" use="optional"/> + <xsd:attribute name="schemeAgencyID" type="xsd:token" 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> + + <!-- Type à spécifier --> + <xsd:attributeGroup name="OpenTypeAttributeGroup"> + <xsd:attribute ref="xml:id" use="optional"/> + <xsd:attribute ref="xlink:href" use="optional"/> + </xsd:attributeGroup> + <xsd:complexType name="OpenType" abstract="true"> + <xsd:sequence> + <xsd:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xsd:sequence> + <xsd:attributeGroup ref="OpenTypeAttributeGroup"/> + </xsd:complexType> + + <xsd:simpleType name="NonEmptyTokenType"> + <xsd:annotation> + <xsd:documentation>Elément ne pouvant être vide.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:token"> + <xsd:minLength value="1"/> + </xsd:restriction> + </xsd:simpleType> + <!-- ID --> + <xsd:simpleType name="DataObjectIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant utilisé pour les objets-données.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:ID"/> + </xsd:simpleType> + <xsd:simpleType name="DataObjectRefIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant servant aux relations des objets-données.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:IDREF"/> + </xsd:simpleType> + <xsd:simpleType name="GroupIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant utilisé pour les groupes d'objets-données.</xsd:documentation> + </xsd:annotation> + <xsd:union> + <xsd:simpleType> + <xsd:restriction base="xsd:ID"/> + </xsd:simpleType> + </xsd:union> + </xsd:simpleType> + <xsd:simpleType name="GroupRefIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant utilisé pour référencer les groupes d'objets-données.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:IDREF"/> + </xsd:simpleType> + <xsd:complexType name="DataObjectRefType"> + <xsd:annotation> + <xsd:documentation>Référence à un objet-données ou à un groupe d'objets-données.</xsd:documentation> + </xsd:annotation> + <xsd:sequence> + <xsd:choice> + <xsd:element name="DataObjectReferenceId" type="DataObjectRefIdType"> + <xsd:annotation> + <xsd:documentation>Référence à un objet-données listé dans les métadonnées de transport.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="DataObjectGroupReferenceId" type="GroupRefIdType"> + <xsd:annotation> + <xsd:documentation>Référence à un groupe d'objets-données listé dans les métadonnées de transport.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:choice> + </xsd:sequence> + <xsd:attribute name="id" type="xsd:ID" use="optional"/> + </xsd:complexType> + + <!-- ID of an ArchiveUnit --> + <xsd:simpleType name="ArchiveUnitIdType"> + <xsd:annotation> + <xsd:documentation>Identifiant utilisé pour les unités d'archives.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:ID"/> + </xsd:simpleType> + <xsd:simpleType name="ArchiveUnitRefIdType"> + <xsd:annotation> + <xsd:documentation>Référence aux identifiants utilisés pour les unités d'archives.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:IDREF"/> + </xsd:simpleType> + + <xsd:simpleType name="SizeInBytesType"> + <xsd:annotation> + <xsd:documentation>Poids des objets-données binaires en bytes.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="xsd:positiveInteger"/> + </xsd:simpleType> + + <!-- Binary encoding --> + <xsd:simpleType name="BinaryType"> + <xsd:annotation> + <xsd:documentation>Représentation binaire : utilisation possible de base64 ou d'hexadécimal.</xsd:documentation> + </xsd:annotation> + <xsd:union memberTypes="xsd:base64Binary xsd:hexBinary"/> + </xsd:simpleType> + + <!-- Digest --> + <xsd:group name="DigestAlgorithmCodeListGroup"> + <xsd:sequence> + <xsd:element name="MessageDigestAlgorithmCodeListVersion" type="CodeType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Liste de l'algorithme de hachage utilisé dans le message.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:group> + <xsd:simpleType name="DigestAlgorithmCodeType"> + <xsd:annotation> + <xsd:documentation>Algorithme de hachage spécifié dans DigestAlgorithmCodeList.</xsd:documentation> + </xsd:annotation> + <xsd:restriction base="NonEmptyTokenType"/> + </xsd:simpleType> + <xsd:complexType name="MessageDigestBinaryObjectType"> + <xsd:simpleContent> + <xsd:extension base="BinaryType"> + <xsd:attribute name="algorithm" type="DigestAlgorithmCodeType" use="required"/> + </xsd:extension> + </xsd:simpleContent> + </xsd:complexType> + + <!-- + ***************************** + *** Types métier + ***************************** + + --> + + <!-- Organisation --> + <xsd:complexType name="OrganizationType"> + <xsd:sequence> + <xsd:element name="Identifier" type="IdentifierType"> + <xsd:annotation> + <xsd:documentation>Identifiant de l'organisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + <xsd:element name="OrganizationDescriptiveMetadata" type="OrganizationDescriptiveMetadataType" minOccurs="0"> + <xsd:annotation> + <xsd:documentation>Métadonnées de description de l'organisation.</xsd:documentation> + </xsd:annotation> + </xsd:element> + </xsd:sequence> + </xsd:complexType> + + <!-- + ***************************** + *** Objets à redéfinir + ***************************** + La redéfinition permet de fixer le nom de la balise tout en permettant la définition du type ultérieurement + --> + + <!-- Métadonnées descriptives pour une organisation --> + <xsd:complexType name="OrganizationDescriptiveMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées de description des organisations.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + + <!-- Signature in Main message block --> + <xsd:complexType name="SignatureMessageType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées dsur la signature.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + + <!-- In CoreMetadataType from seda-2.2-technical.xsd: Technical Metadata Content --> + <xsd:complexType name="TextTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques de base pour les objets-données de type texte(XML, JSON, CSV, ...).</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + <xsd:complexType name="DocumentTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques de base pour les objets-données de type document (Word, PDF, XLS, LibreOffice, ...).</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + <xsd:complexType name="ImageTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques de base pour les objets-données de type image.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + <xsd:complexType name="AudioTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques de base pour les objets-données de type audio.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + <xsd:complexType name="VideoTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques de base pour les objets-données de type video.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + <xsd:complexType name="DescriptiveTechnicalMetadataType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques et/ou descriptives définies dans un schéma par un service producteur ou versant mais n'étant pas présentes dans les métadonnées de base.</xsd:documentation> + </xsd:annotation> + <xsd:complexContent> + <xsd:extension base="OpenType"/> + </xsd:complexContent> + </xsd:complexType> + + <!-- + ******************************************* + *** Objets à spécifier par substitution + ******************************************* + La substitution permet de ne pas fixer le nom de la balise, d'en autoriser plusieurs et de laisser l'implémentation choisir en fonction de ses besoins. + --> + <!-- In ObjectGroup from seda-2-0-ontology.xsd: Extra Descriptive Metadata Content --> + <xsd:element name="ObjectGroupExtenstionAbstract" abstract="true"> + <xsd:annotation> + <xsd:documentation>Permet d'étendre ObjectGroup avec d'autres métadonnées descriptives.</xsd:documentation> + </xsd:annotation> + </xsd:element> + + <!-- In PhysicalTechnicalDescriptionGroup from seda-2.2-technical.xsd: extra dimension techncal description for PhysicalDataObject --> + <xsd:element name="OtherDimensionsAbstract" abstract="true"> + <xsd:annotation> + <xsd:documentation>Permet d'étendre <OtherDimensions> avec d'autres métadonnées de description des objets-données physiques.</xsd:documentation> + </xsd:annotation> + </xsd:element> + + <!-- In CoreMetadataType from seda-2.2-technical.xsd: extra Core TechnicalMetadata (Database, 3D, plan, ...) --> + <xsd:element name="OtherCoreTechnicalMetadataAbstract" abstract="true" type="OpenType"> + <xsd:annotation> + <xsd:documentation>Contient toutes les métadonnées techniques de base pour d'autres types.</xsd:documentation> + </xsd:annotation> + </xsd:element> + + <!-- In ArchiveUnitType from seda-2.2-descriptive.xsd: Abstract for ArchiveUnit reference from within EAS --> + <xsd:element name="ArchiveUnitReferenceAbstract" abstract="true"> + <xsd:annotation> + <xsd:documentation>Contient les requêtes nécessaires pour trouver un ArchiveUnit et pointer sur lui dans un prochain ArchiveUnit. + Permet de référencer un noeud déjà existant dans un arbre à partir d'un transfert précédent.</xsd:documentation> + </xsd:annotation> + </xsd:element> + + <!-- In ManagementGroup from seda-2.2-management.xsd: for Management extension --> + <xsd:element name="OtherManagementAbstract" abstract="true"> + <xsd:annotation> + <xsd:documentation>Utilisé par exemple pour manipuler un ArchiveUnit déjà existant dans le système d'archivage électronique.</xsd:documentation> + </xsd:annotation> + </xsd:element> + + <!-- In CodeListVersionsType from seda-2.2-main.xsd: If needed, extra CodeList could be added --> + <xsd:element name="OtherCodeListAbstract" abstract="true" type="CodeType"> + <xsd:annotation> + <xsd:documentation>Permet d'ajouter de nouvelles listes de codes si l'ajout d'autres métadonnées l'impose.</xsd:documentation> + </xsd:annotation> + </xsd:element> + + <!-- In EventGroup from seda-2.2-ontology.xsd: If needed, extra event could be added --> + <xsd:element name="EventAbstract" abstract="true"> + <xsd:annotation> + <xsd:documentation>Permet d'ajouter de nouveau types d'événements dans l'ontologie.</xsd:documentation> + </xsd:annotation> + </xsd:element> + +</xsd:schema> + diff --git a/webroot/xmlSchemas/seda_v2-2/xlink.xsd b/webroot/xmlSchemas/seda_v2-2/xlink.xsd new file mode 100644 index 0000000000000000000000000000000000000000..f73b79d2cd64c9af6c9a8f96d722f1123fd1d416 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/xlink.xsd @@ -0,0 +1,271 @@ +<?xml version='1.0' encoding='UTF-8'?> +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.w3.org/1999/xlink" xmlns:xlink="http://www.w3.org/1999/xlink"> + + <xs:annotation> + <xs:documentation>This schema document provides attribute declarations and + attribute group, complex type and simple type definitions which can be used in + the construction of user schemas to define the structure of particular linking + constructs, e.g. + <![CDATA[ +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:xl="http://www.w3.org/1999/xlink"> + + <xs:import namespace="http://www.w3.org/1999/xlink" + location="http://www.w3.org/1999/xlink.xsd"> + + <xs:element name="mySimple"> + <xs:complexType> + ... + <xs:attributeGroup ref="xl:simpleAttrs"/> + ... + </xs:complexType> + </xs:element> + ... +</xs:schema>]]></xs:documentation> + </xs:annotation> + + <!--<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>--> + <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/> + + <xs:attribute name="type" type="xlink:typeType"/> + + <xs:simpleType name="typeType"> + <xs:restriction base="xs:token"> + <xs:enumeration value="simple"/> + <xs:enumeration value="extended"/> + <xs:enumeration value="title"/> + <xs:enumeration value="resource"/> + <xs:enumeration value="locator"/> + <xs:enumeration value="arc"/> + </xs:restriction> + </xs:simpleType> + + <xs:attribute name="href" type="xlink:hrefType"/> + + <xs:simpleType name="hrefType"> + <xs:restriction base="xs:anyURI"/> + </xs:simpleType> + + <xs:attribute name="role" type="xlink:roleType"/> + + <xs:simpleType name="roleType"> + <xs:restriction base="xs:anyURI"> + <xs:minLength value="1"/> + </xs:restriction> + </xs:simpleType> + + <xs:attribute name="arcrole" type="xlink:arcroleType"/> + + <xs:simpleType name="arcroleType"> + <xs:restriction base="xs:anyURI"> + <xs:minLength value="1"/> + </xs:restriction> + </xs:simpleType> + + <xs:attribute name="title" type="xlink:titleAttrType"/> + + <xs:simpleType name="titleAttrType"> + <xs:restriction base="xs:string"/> + </xs:simpleType> + + <xs:attribute name="show" type="xlink:showType"/> + + <xs:simpleType name="showType"> + <xs:restriction base="xs:token"> + <xs:enumeration value="new"/> + <xs:enumeration value="replace"/> + <xs:enumeration value="embed"/> + <xs:enumeration value="other"/> + <xs:enumeration value="none"/> + </xs:restriction> + </xs:simpleType> + + <xs:attribute name="actuate" type="xlink:actuateType"/> + + <xs:simpleType name="actuateType"> + <xs:restriction base="xs:token"> + <xs:enumeration value="onLoad"/> + <xs:enumeration value="onRequest"/> + <xs:enumeration value="other"/> + <xs:enumeration value="none"/> + </xs:restriction> + </xs:simpleType> + + <xs:attribute name="label" type="xlink:labelType"/> + + <xs:simpleType name="labelType"> + <xs:restriction base="xs:NCName"/> + </xs:simpleType> + + <xs:attribute name="from" type="xlink:fromType"/> + + <xs:simpleType name="fromType"> + <xs:restriction base="xs:NCName"/> + </xs:simpleType> + + <xs:attribute name="to" type="xlink:toType"/> + + <xs:simpleType name="toType"> + <xs:restriction base="xs:NCName"/> + </xs:simpleType> + + <xs:attributeGroup name="simpleAttrs"> + <xs:attribute ref="xlink:type" fixed="simple"/> + <xs:attribute ref="xlink:href"/> + <xs:attribute ref="xlink:role"/> + <xs:attribute ref="xlink:arcrole"/> + <xs:attribute ref="xlink:title"/> + <xs:attribute ref="xlink:show"/> + <xs:attribute ref="xlink:actuate"/> + </xs:attributeGroup> + + <xs:group name="simpleModel"> + <xs:sequence> + <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:group> + + <xs:complexType mixed="true" name="simple"> + <xs:annotation> + <xs:documentation> + Intended for use as the type of user-declared elements to make them + simple links. + </xs:documentation> + </xs:annotation> + <xs:group ref="xlink:simpleModel"/> + <xs:attributeGroup ref="xlink:simpleAttrs"/> + </xs:complexType> + + <xs:attributeGroup name="extendedAttrs"> + <xs:attribute ref="xlink:type" fixed="extended" use="required"/> + <xs:attribute ref="xlink:role"/> + <xs:attribute ref="xlink:title"/> + </xs:attributeGroup> + + <xs:group name="extendedModel"> + <xs:choice> + <xs:element ref="xlink:title"/> + <xs:element ref="xlink:resource"/> + <xs:element ref="xlink:locator"/> + <xs:element ref="xlink:arc"/> + </xs:choice> + </xs:group> + + <xs:complexType name="extended"> + <xs:annotation> + <xs:documentation> + Intended for use as the type of user-declared elements to make them + extended links. + Note that the elements referenced in the content model are all abstract. + The intention is that by simply declaring elements with these as their + substitutionGroup, all the right things will happen. + </xs:documentation> + </xs:annotation> + <xs:group ref="xlink:extendedModel" minOccurs="0" maxOccurs="unbounded"/> + <xs:attributeGroup ref="xlink:extendedAttrs"/> + </xs:complexType> + + <xs:element name="title" type="xlink:titleEltType" abstract="true"/> + + <xs:attributeGroup name="titleAttrs"> + <xs:attribute ref="xlink:type" fixed="title" use="required"/> + <xs:attribute ref="xml:lang"> + <xs:annotation> + <xs:documentation> + xml:lang is not required, but provides much of the + motivation for title elements in addition to attributes, and so + is provided here for convenience. + </xs:documentation> + </xs:annotation> + </xs:attribute> + </xs:attributeGroup> + + <xs:group name="titleModel"> + <xs:sequence> + <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:group> + + <xs:complexType mixed="true" name="titleEltType"> + <xs:group ref="xlink:titleModel"/> + <xs:attributeGroup ref="xlink:titleAttrs"/> + </xs:complexType> + + <xs:element name="resource" type="xlink:resourceType" abstract="true"/> + + <xs:attributeGroup name="resourceAttrs"> + <xs:attribute ref="xlink:type" fixed="resource" use="required"/> + <xs:attribute ref="xlink:role"/> + <xs:attribute ref="xlink:title"/> + <xs:attribute ref="xlink:label"/> + </xs:attributeGroup> + + <xs:group name="resourceModel"> + <xs:sequence> + <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:group> + + <xs:complexType mixed="true" name="resourceType"> + <xs:group ref="xlink:resourceModel"/> + <xs:attributeGroup ref="xlink:resourceAttrs"/> + </xs:complexType> + + <xs:element name="locator" type="xlink:locatorType" abstract="true"/> + + <xs:attributeGroup name="locatorAttrs"> + <xs:attribute ref="xlink:type" fixed="locator" use="required"/> + <xs:attribute ref="xlink:href" use="required"/> + <xs:attribute ref="xlink:role"/> + <xs:attribute ref="xlink:title"/> + <xs:attribute ref="xlink:label"> + <xs:annotation> + <xs:documentation> + label is not required, but locators have no particular + XLink function if they are not labeled. + </xs:documentation> + </xs:annotation> + </xs:attribute> + </xs:attributeGroup> + + <xs:group name="locatorModel"> + <xs:sequence> + <xs:element ref="xlink:title" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:group> + + <xs:complexType name="locatorType"> + <xs:group ref="xlink:locatorModel"/> + <xs:attributeGroup ref="xlink:locatorAttrs"/> + </xs:complexType> + + <xs:element name="arc" type="xlink:arcType" abstract="true"/> + + <xs:attributeGroup name="arcAttrs"> + <xs:attribute ref="xlink:type" fixed="arc" use="required"/> + <xs:attribute ref="xlink:arcrole"/> + <xs:attribute ref="xlink:title"/> + <xs:attribute ref="xlink:show"/> + <xs:attribute ref="xlink:actuate"/> + <xs:attribute ref="xlink:from"/> + <xs:attribute ref="xlink:to"> + <xs:annotation> + <xs:documentation> + from and to have default behavior when values are missing + </xs:documentation> + </xs:annotation> + </xs:attribute> + </xs:attributeGroup> + + <xs:group name="arcModel"> + <xs:sequence> + <xs:element ref="xlink:title" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:group> + + <xs:complexType name="arcType"> + <xs:group ref="xlink:arcModel"/> + <xs:attributeGroup ref="xlink:arcAttrs"/> + </xs:complexType> + +</xs:schema> diff --git a/webroot/xmlSchemas/seda_v2-2/xml.xsd b/webroot/xmlSchemas/seda_v2-2/xml.xsd new file mode 100644 index 0000000000000000000000000000000000000000..1616b3ef0302ec55fa3dd7b813a93b451830a7e8 --- /dev/null +++ b/webroot/xmlSchemas/seda_v2-2/xml.xsd @@ -0,0 +1,286 @@ +<?xml version='1.0'?> +<xs:schema targetNamespace="http://www.w3.org/XML/1998/namespace" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns ="http://www.w3.org/1999/xhtml" + xml:lang="en"> + + <xs:annotation> + <xs:documentation> + <div> + <h1>About the XML namespace</h1> + + <div class="bodytext"> + <p> + This schema document describes the XML namespace, in a form + suitable for import by other schema documents. + </p> + <p> + See <a href="http://www.w3.org/XML/1998/namespace.html"> + http://www.w3.org/XML/1998/namespace.html</a> and + <a href="http://www.w3.org/TR/REC-xml"> + http://www.w3.org/TR/REC-xml</a> for information + about this namespace. + </p> + <p> + Note that local names in this namespace are intended to be + defined only by the World Wide Web Consortium or its subgroups. + The names currently defined in this namespace are listed below. + They should not be used with conflicting semantics by any Working + Group, specification, or document instance. + </p> + <p> + See further below in this document for more information about <a + href="#usage">how to refer to this schema document from your own + XSD schema documents</a> and about <a href="#nsversioning">the + namespace-versioning policy governing this schema document</a>. + </p> + </div> + </div> + </xs:documentation> + </xs:annotation> + + <xs:attribute name="lang"> + <xs:annotation> + <xs:documentation> + <div> + + <h3>lang (as an attribute name)</h3> + <p> + denotes an attribute whose value + is a language code for the natural language of the content of + any element; its value is inherited. This name is reserved + by virtue of its definition in the XML specification.</p> + + </div> + <div> + <h4>Notes</h4> + <p> + Attempting to install the relevant ISO 2- and 3-letter + codes as the enumerated possible values is probably never + going to be a realistic possibility. + </p> + <p> + See BCP 47 at <a href="http://www.rfc-editor.org/rfc/bcp/bcp47.txt"> + http://www.rfc-editor.org/rfc/bcp/bcp47.txt</a> + and the IANA language subtag registry at + <a href="http://www.iana.org/assignments/language-subtag-registry"> + http://www.iana.org/assignments/language-subtag-registry</a> + for further information. + </p> + <p> + The union allows for the 'un-declaration' of xml:lang with + the empty string. + </p> + </div> + </xs:documentation> + </xs:annotation> + <xs:simpleType> + <xs:union memberTypes="xs:language"> + <xs:simpleType> + <xs:restriction base="xs:string"> + <xs:enumeration value=""/> + </xs:restriction> + </xs:simpleType> + </xs:union> + </xs:simpleType> + </xs:attribute> + + <xs:attribute name="space"> + <xs:annotation> + <xs:documentation> + <div> + + <h3>space (as an attribute name)</h3> + <p> + denotes an attribute whose + value is a keyword indicating what whitespace processing + discipline is intended for the content of the element; its + value is inherited. This name is reserved by virtue of its + definition in the XML specification.</p> + + </div> + </xs:documentation> + </xs:annotation> + <xs:simpleType> + <xs:restriction base="xs:NCName"> + <xs:enumeration value="default"/> + <xs:enumeration value="preserve"/> + </xs:restriction> + </xs:simpleType> + </xs:attribute> + + <xs:attribute name="base" type="xs:anyURI"> <xs:annotation> + <xs:documentation> + <div> + + <h3>base (as an attribute name)</h3> + <p> + denotes an attribute whose value + provides a URI to be used as the base for interpreting any + relative URIs in the scope of the element on which it + appears; its value is inherited. This name is reserved + by virtue of its definition in the XML Base specification.</p> + + <p> + See <a + href="http://www.w3.org/TR/xmlbase/">http://www.w3.org/TR/xmlbase/</a> + for information about this attribute. + </p> + </div> + </xs:documentation> + </xs:annotation> + </xs:attribute> + + <xs:attribute name="id" type="xs:ID"> + <xs:annotation> + <xs:documentation> + <div> + + <h3>id (as an attribute name)</h3> + <p> + denotes an attribute whose value + should be interpreted as if declared to be of type ID. + This name is reserved by virtue of its definition in the + xml:id specification.</p> + + <p> + See <a + href="http://www.w3.org/TR/xml-id/">http://www.w3.org/TR/xml-id/</a> + for information about this attribute. + </p> + </div> + </xs:documentation> + </xs:annotation> + </xs:attribute> + + <xs:attributeGroup name="specialAttrs"> + <xs:attribute ref="xml:base"/> + <xs:attribute ref="xml:lang"/> + <xs:attribute ref="xml:space"/> + <xs:attribute ref="xml:id"/> + </xs:attributeGroup> + + <xs:annotation> + <xs:documentation> + <div> + + <h3>Father (in any context at all)</h3> + + <div class="bodytext"> + <p> + denotes Jon Bosak, the chair of + the original XML Working Group. This name is reserved by + the following decision of the W3C XML Plenary and + XML Coordination groups: + </p> + <blockquote> + <p> + In appreciation for his vision, leadership and + dedication the W3C XML Plenary on this 10th day of + February, 2000, reserves for Jon Bosak in perpetuity + the XML name "xml:Father". + </p> + </blockquote> + </div> + </div> + </xs:documentation> + </xs:annotation> + + <xs:annotation> + <xs:documentation> + <div xml:id="usage" id="usage"> + <h2><a name="usage">About this schema document</a></h2> + + <div class="bodytext"> + <p> + This schema defines attributes and an attribute group suitable + for use by schemas wishing to allow <code>xml:base</code>, + <code>xml:lang</code>, <code>xml:space</code> or + <code>xml:id</code> attributes on elements they define. + </p> + <p> + To enable this, such a schema must import this schema for + the XML namespace, e.g. as follows: + </p> + <pre> + <schema . . .> + . . . + <import namespace="http://www.w3.org/XML/1998/namespace" + schemaLocation="http://www.w3.org/2001/xml.xsd"/> + </pre> + <p> + or + </p> + <pre> + <import namespace="http://www.w3.org/XML/1998/namespace" + schemaLocation="http://www.w3.org/2009/01/xml.xsd"/> + </pre> + <p> + Subsequently, qualified reference to any of the attributes or the + group defined below will have the desired effect, e.g. + </p> + <pre> + <type . . .> + . . . + <attributeGroup ref="xml:specialAttrs"/> + </pre> + <p> + will define a type which will schema-validate an instance element + with any of those attributes. + </p> + </div> + </div> + </xs:documentation> + </xs:annotation> + + <xs:annotation> + <xs:documentation> + <div id="nsversioning" xml:id="nsversioning"> + <h2><a name="nsversioning">Versioning policy for this schema document</a></h2> + <div class="bodytext"> + <p> + In keeping with the XML Schema WG's standard versioning + policy, this schema document will persist at + <a href="http://www.w3.org/2009/01/xml.xsd"> + http://www.w3.org/2009/01/xml.xsd</a>. + </p> + <p> + At the date of issue it can also be found at + <a href="http://www.w3.org/2001/xml.xsd"> + http://www.w3.org/2001/xml.xsd</a>. + </p> + <p> + The schema document at that URI may however change in the future, + in order to remain compatible with the latest version of XML + Schema itself, or with the XML namespace itself. In other words, + if the XML Schema or XML namespaces change, the version of this + document at <a href="http://www.w3.org/2001/xml.xsd"> + http://www.w3.org/2001/xml.xsd + </a> + will change accordingly; the version at + <a href="http://www.w3.org/2009/01/xml.xsd"> + http://www.w3.org/2009/01/xml.xsd + </a> + will not change. + </p> + <p> + Previous dated (and unchanging) versions of this schema + document are at: + </p> + <ul> + <li><a href="http://www.w3.org/2009/01/xml.xsd"> + http://www.w3.org/2009/01/xml.xsd</a></li> + <li><a href="http://www.w3.org/2007/08/xml.xsd"> + http://www.w3.org/2007/08/xml.xsd</a></li> + <li><a href="http://www.w3.org/2004/10/xml.xsd"> + http://www.w3.org/2004/10/xml.xsd</a></li> + <li><a href="http://www.w3.org/2001/03/xml.xsd"> + http://www.w3.org/2001/03/xml.xsd</a></li> + </ul> + </div> + </div> + </xs:documentation> + </xs:annotation> + +</xs:schema> +