<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xd="http://www.oxygenxml.com/ns/doc/xsl" version="2.0"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
xmlns:skos="http://www.w3.org/2004/02/skos/core#"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:inist="http://www.inist.fr/Ontology#"
xmlns:exslt="http://exslt.org/common"
xmlns:dcterms="http://purl.org/dc/terms/"
xmlns:skosxl="http://www.w3.org/2008/05/skos-xl#"
xmlns:tps="http://www.termsciences.fr/vocabs/"
xmlns:owl="http://www.w3.org/2002/07/owl#"
xmlns:isothes="http://purl.org/iso25964/skos-thes#"
exclude-result-prefixes="xsl xd rdf skos skosxl dc dcterms cc inist tps" >
<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes" omit-xml-declaration="yes"/>
<!-- <xsl:param name="page"/>
<xsl:template match="/">
<xsl:text disable-output-escaping='yes'>
<!DOCTYPE html>
</xsl:text>
</xsl:template>-->
<xd:doc scope="stylesheet">
<xd:desc>
<xd:p><xd:b>Created on:</xd:b> Apr 14, 2016</xd:p>
<xd:p><xd:b>Modified on:</xd:b>Sep 10, 2019</xd:p>
<xd:p><xd:b>Modified on:</xd:b>June 06, 2020</xd:p>
<xd:p><xd:b>Modified on:</xd:b> Dec 22, 2020</xd:p>
<xd:p><xd:b>Modified on:</xd:b> Jun 04, 2021</xd:p>
<xd:p><xd:b>Author:</xd:b> khayari</xd:p>
<xd:p></xd:p>
</xd:desc>
</xd:doc>
<xsl:key name="ConceptSchemeElemByName" match="//skos:ConceptScheme/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="ConceptSchemeElemByNameRDF" match="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="ConceptElemByName" match="//skos:Concept/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="ConceptElemByNameRDF" match="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']]/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="CollectionElemByName" match="//skos:Collection/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="CollectionElemByNameCG" match="//isothes:ConceptGroup/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="CollectionElemByNameRDF" match="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Collection' or @rdf:resource='http://purl.org/iso25964/skos-thes#ConceptGroup']]/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="LabelElemByName" match="//skosxl:Label/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:key name="LabelElemByNameRDF" match="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2008/05/skos-xl#Label']]/*" use="concat(name(),'_',@xml:lang)"/>
<xsl:variable name="fichier" select="/rdf:RDF"/>
<xsl:variable name="apos">'</xsl:variable>
<xsl:variable name="quot">"</xsl:variable>
<xsl:variable name="crochetG">[</xsl:variable>
<xsl:variable name="crochetD">]</xsl:variable>
<!-- <xsl:variable name="newline"><xsl:text> </xsl:text></xsl:variable>-->
<xsl:variable name="newline" select="' '"/>
<xsl:variable name="tab"><xsl:text> </xsl:text></xsl:variable>
<!-- <xsl:variable name="tab" select="'	'"/> --><!-- ne fonctionne pas -->
<xsl:variable name="carriageReturn"><xsl:text> </xsl:text></xsl:variable>
<xsl:variable name="uriRessource">
<xsl:choose>
<xsl:when test="//skos:ConceptScheme">
<xsl:value-of select="//skos:ConceptScheme/@rdf:about"/>
</xsl:when>
<xsl:when test="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/@rdf:about"/>
</xsl:when>
<xsl:when test="//owl:Ontology[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="//owl:Ontology[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/@rdf:about"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="rdf:RDF/skos:Concept[1]/skos:inScheme/@rdf:resource or rdf:RDF/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']][1]/skos:inScheme/@rdf:resource"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="languesRessource">
<xsl:for-each select="distinct-values(//skos:prefLabel/@xml:lang | //rdfs:label/@xml:lang)">
<xsl:sort select="."/>
<lng>
<xsl:value-of select="."/>
</lng>
</xsl:for-each>
</xsl:variable>
<xsl:variable name="champsRessource">
<xsl:for-each select="distinct-values(//skos:Concept/node())">
<xsl:sort select="."/>
<field>
<xsl:value-of select="."/>
</field>
</xsl:for-each>
</xsl:variable>
<!--calcul du pourcentage de structuration -->
<xsl:variable name="NbBroader" select="count(//skos:broader)"/>
<xsl:variable name="NbConcepts">
<xsl:choose>
<xsl:when test="//skos:Concept">
<xsl:value-of select="count(//skos:Concept)"/>
</xsl:when>
<xsl:when test="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']]">
<xsl:value-of select="count(//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']])"/>
</xsl:when>
</xsl:choose>
</xsl:variable>
<xsl:variable name="structuration" select="round($NbBroader div $NbConcepts) * 100"/>
<!--===================================================
Contrôles de cohérence des fichiers SKOS
====================================================-->
<xsl:template match="rdf:RDF">
<!-- résultat stocké dans une variable -->
<xsl:variable name="CONTROLES">
<Controle>
<xsl:if test="//skos:Concept">
<!-- pas d'attribut xml:lang -->
<xsl:if test="skos:Concept/skos:prefLabel[not(@xml:lang)] | skos:Concept/rdfs:label[not(@xml:lang)]">
<tr>
<td class="A">@lang</td>
<td>Terme préférentiel sans code langue</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="skos:Concept[skos:prefLabel[not(@xml:lang)]]/@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:Concept[skos:prefLabel[not(@xml:lang)]]/skos:prefLabel[not(@xml:lang)][1] | skos:Concept[rdfs:label[not(@xml:lang)]]/rdfs:label[not(@xml:lang)][1]"/>
</a>
<xsl:text> présente un terme préférentiel qui n'a pas d'attribut code langue ("xml:lang").</xsl:text>
</td>
</tr>
</xsl:if>
<!-- recherche de doublons au niveau des termes au sein du même concept ou entre 2 concepts différents-->
<xsl:for-each select="//skos:prefLabel[parent::skos:Concept and not(.='')] | //rdfs:label[parent::skos:Concept and not(.='')]">
<xsl:call-template name="TermUniqueness">
<xsl:with-param name="language" select="@xml:lang"/>
<xsl:with-param name="term" select="."/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="position" select="position()"/>
</xsl:call-template>
</xsl:for-each>
<xsl:for-each select="//skos:altLabel[parent::skos:Concept and not(.='') ]">
<xsl:call-template name="TermUniqueness2">
<xsl:with-param name="language" select="@xml:lang"/>
<xsl:with-param name="term" select="."/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="position" select="position()"/>
</xsl:call-template>
</xsl:for-each>
<xsl:for-each select="//skos:hiddenLabel[parent::skos:Concept and not(.='')]">
<xsl:call-template name="TermUniqueness3">
<xsl:with-param name="language" select="@xml:lang"/>
<xsl:with-param name="term" select="."/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="position" select="position()"/>
</xsl:call-template>
</xsl:for-each>
<!-- recherche dd'orphelins-->
<xsl:if test="$structuration > 50">
<xsl:for-each select="//skos:Concept[not(skos:broader)]">
<xsl:variable name="uriConcept" select="@rdf:about"/>
<xsl:variable name="prefFre" select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
<xsl:choose>
<xsl:when test="skos:topConceptOf | //skos:hasTopConcept[@rdf:resource=$uriConcept] ">
</xsl:when>
<xsl:otherwise>
<xsl:if test="not($fichier//skos:broader[@rdf:resource=$uriConcept])">
<tr>
<td class="A">R-OR</td>
<td>Concept orphelin</td>
<td>Le concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> est orphelin.
</td>
</tr>
</xsl:if>
</xsl:otherwise>
</xsl:choose>
<!-- <xsl:call-template name="orphelin">
<xsl:with-param name="uriConcept" select="@rdf:about"/>
<xsl:with-param name="prefFre" select="skos:prefLabel[@xml:lang='fr'][1]"/>
</xsl:call-template>-->
</xsl:for-each>
</xsl:if>
</xsl:if>
<xsl:if test="//rdf:Description[rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']">
<!-- pas d'attribut xml:lang -->
<xsl:if test="rdf:Description[rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']/skos:prefLabel[not(@xml:lang)] | rdf:Description[rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']/rdfs:label[not(@xml:lang)]">
<tr>
<td class="A">@lang</td>
<td>Terme préférentiel sans code langue</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="rdf:Description[rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept' and skos:prefLabel[not(@xml:lang)]]/@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="rdf:Description[rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept' and skos:prefLabel[not(@xml:lang)]]/skos:prefLabel[not(@xml:lang)][1] | rdf:Description[rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept' and rdfs:label[not(@xml:lang)]]/rdfs:label[not(@xml:lang)][1]"/>
</a>
<xsl:text> présente un terme préférentiel qui n'a pas d'attribut code langue ("xml:lang").</xsl:text>
</td>
</tr>
</xsl:if>
<!-- recherche de doublons au niveau des termes au sein du même concept ou entre 2 concepts différents-->
<xsl:for-each select="//skos:prefLabel[../rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] | //rdfs:label[../rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] ">
<xsl:call-template name="TermUniqueness">
<xsl:with-param name="language" select="@xml:lang"/>
<xsl:with-param name="term" select="."/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="position" select="position()"/>
</xsl:call-template>
</xsl:for-each>
<xsl:for-each select="//skos:altLabel[../rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']">
<xsl:call-template name="TermUniqueness2">
<xsl:with-param name="language" select="@xml:lang"/>
<xsl:with-param name="term" select="."/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="position" select="position()"/>
</xsl:call-template>
</xsl:for-each>
<xsl:for-each select="//skos:hiddenLabel[../rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']">
<xsl:call-template name="TermUniqueness3">
<xsl:with-param name="language" select="@xml:lang"/>
<xsl:with-param name="term" select="."/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="position" select="position()"/>
</xsl:call-template>
</xsl:for-each>
<!-- recherche dd'orphelins-->
<xsl:if test="$structuration > 50">
<xsl:for-each select="//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and not(skos:broader)]">
<xsl:variable name="uriConcept" select="@rdf:about"/>
<xsl:variable name="prefFre" select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
<xsl:choose>
<xsl:when test="skos:topConceptOf | //skos:hasTopConcept[@rdf:resource=$uriConcept] ">
</xsl:when>
<xsl:otherwise>
<xsl:if test="not($fichier//skos:broader[@rdf:resource=$uriConcept])">
<tr>
<td class="A">R-OR</td>
<td>Concept orphelin</td>
<td>Le concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> est orphelin.
</td>
</tr>
</xsl:if>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
</xsl:if>
</xsl:if>
<xsl:apply-templates select="skos:Concept">
<!-- <xsl:sort select="skos:prefLabel[@xml:lang='fr'][1]"/>-->
</xsl:apply-templates>
<xsl:apply-templates select="rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']]">
<!-- <xsl:sort select="skos:prefLabel[@xml:lang='fr'][1]"/>-->
</xsl:apply-templates>
</Controle>
</xsl:variable>
<xsl:apply-templates select="exslt:node-set($CONTROLES)//Controle"/>
</xsl:template>
<!--==========================================================
node-set Controle
==========================================================-->
<xsl:template match="Controle">
<html lang="fr">
<head>
<title>Contrôles du fichier : <xsl:choose>
<xsl:when test="$fichier/skos:ConceptScheme">
<xsl:value-of select="$fichier/skos:ConceptScheme/dc:title[@xml:lang='fr']"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/dc:title[@xml:lang='fr']"/>
</xsl:when>
</xsl:choose>
</title>
<meta http-equiv='Content-Type' content='text/html; charset=UTF-8'/>
<link rel="stylesheet" href="anomalies.css" />
<link rel="stylesheet" href="modal.css" />
<link rel="stylesheet" href="header2.css" />
<style id="compiled-css" type="text/css">
table, tr, td, th
{
border: 1px solid black;
border-collapse:collapse;
}
tr.header
{
cursor:pointer;
}
</style>
<script src="http://code.jquery.com/jquery-1.9.1.js"><xsl:text> </xsl:text></script>
<script type="text/javascript">
<![CDATA[
$(function(){
$('.header').click(function(){
$(this).find('span').text(function(_, value){return value=='-'?'+':'-'});
$(this).nextUntil('tr.header').slideToggle(100, function(){
});
});
});
]]>
</script>
</head>
<body>
<h3>Statistiques du fichier <em>
<xsl:choose>
<xsl:when test="$fichier/skos:ConceptScheme">
<xsl:value-of select="$fichier/skos:ConceptScheme/dc:title[@xml:lang='fr']"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/dc:title[@xml:lang='fr']"/>
</xsl:when>
</xsl:choose>
</em> :</h3>
<table class="anomalies">
<thead>
<tr>
<!--<tr class="header">-->
<th>Données</th>
<th>Détails</th>
</tr>
</thead>
<!-- élement ConceptScheme -->
<!--
<tr class="header">
<th colspan="2"><span>-</span><mark>Schéma(s) de concepts</mark>. La ressource contient <xsl:value-of select="count($fichier/skos:ConceptScheme)"/> schéma(s) de concepts. [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skos:ConceptScheme/*[generate-id()=generate-id(key('ConceptSchemeElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans skos:ConceptScheme</td>
<td>Élément utilisé <xsl:value-of select="count(key('ConceptSchemeElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each> -->
<xsl:if test="$fichier//skos:ConceptScheme or $fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']] ">
<tr class="header">
<th colspan="2"><span>-</span><mark>Schéma(s) de concepts</mark>. La ressource contient
<xsl:choose>
<xsl:when test="$fichier/skos:ConceptScheme">
<xsl:value-of select="count($fichier/skos:ConceptScheme)"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="count($fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']])"/>
</xsl:when>
</xsl:choose> schéma(s) de concepts. [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skos:ConceptScheme/*[generate-id()=generate-id(key('ConceptSchemeElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "skos:ConceptScheme"</td>
<td>Élément utilisé <xsl:value-of select="count(key('ConceptSchemeElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<xsl:for-each select="$fichier//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/*[generate-id()=generate-id(key('ConceptSchemeElemByNameRDF', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "rdf:Description" de type "ConceptScheme"</td>
<td>Élément utilisé <xsl:value-of select="count(key('ConceptSchemeElemByNameRDF', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
</xsl:if>
<!-- élément Concept -->
<tr class="header">
<th colspan="2"><span>-</span><mark>Concepts</mark>. La ressource contient
<xsl:choose>
<xsl:when test="$fichier/skos:Concept">
<xsl:value-of select="count($fichier/skos:Concept)"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']]">
<xsl:value-of select="count($fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']])"/>
</xsl:when>
</xsl:choose> concepts. [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skos:Concept/*[generate-id()=generate-id(key('ConceptElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "skos:Concept"</td>
<td>Élément utilisé <xsl:value-of select="count(key('ConceptElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<xsl:for-each select="$fichier//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']]/*[generate-id()=generate-id(key('ConceptElemByNameRDF', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "rdf:Description" de type "Concept"</td>
<td>Élément utilisé <xsl:value-of select="count(key('ConceptElemByNameRDF', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<!-- <tr class="header">
<th colspan="2"><span>-</span><mark>Concepts</mark>. La ressource contient <xsl:value-of select="count($fichier/skos:Concept)"/> concepts. [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skos:Concept/*[generate-id()=generate-id(key('ConceptElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans skos:Concept</td>
<td>Élément utilisé <xsl:value-of select="count(key('ConceptElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>-->
<xsl:if test="$fichier//skos:Collection or $fichier/isothes:ConceptGroup or $fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Collection' or @rdf:resource='http://purl.org/iso25964/skos-thes#ConceptGroup']] ">
<!-- élément Collection -->
<!--<tr class="header">
<th colspan="2"><span>-</span><mark>Collections</mark>. La ressource contient <xsl:value-of select="count($fichier/skos:Collection)"/> collections. [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skos:Collection/*[generate-id()=generate-id(key('CollectionElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans skos:Collection</td>
<td>Élément utilisé <xsl:value-of select="count(key('CollectionElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>-->
<!-- élement Collection -->
<tr class="header">
<th colspan="2"><span>-</span><mark>Collections</mark>. La ressource contient
<xsl:choose>
<xsl:when test="$fichier/skos:Collection">
<xsl:value-of select="count($fichier/skos:Collection)"/>
</xsl:when>
<xsl:when test="$fichier/isothes:ConceptGroup">
<xsl:value-of select="count($fichier/isothes:ConceptGroup)"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Collection' or @rdf:resource='http://purl.org/iso25964/skos-thes#ConceptGroup']]">
<xsl:value-of select="count($fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Collection' or @rdf:resource='http://purl.org/iso25964/skos-thes#ConceptGroup']])"/>
</xsl:when>
</xsl:choose> collections. [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skos:Collection/*[generate-id()=generate-id(key('CollectionElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "skos:Collection"</td>
<td>Élément utilisé <xsl:value-of select="count(key('CollectionElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<xsl:for-each select="$fichier//isothes:ConceptGroup/*[generate-id()=generate-id(key('CollectionElemByNameCG', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "skos:ConceptGroup"</td>
<td>Élément utilisé <xsl:value-of select="count(key('CollectionElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<xsl:for-each select="$fichier//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Collection' or @rdf:resource='http://purl.org/iso25964/skos-thes#ConceptGroup']]/*[generate-id()=generate-id(key('CollectionElemByNameRDF', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "rdf:Description" de type "Collection/ConceptGroup"</td>
<td>Élément utilisé <xsl:value-of select="count(key('CollectionElemByNameRDF', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
</xsl:if>
<!-- élément Label -->
<xsl:if test="$fichier//skosxl:Label or $fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2008/05/skos-xl#Label']]">
<tr class="header">
<th colspan="2"><span>-</span><mark>Labels (skosxl)</mark>. La ressource contient
<xsl:choose>
<xsl:when test="$fichier/skosxl:Label">
<xsl:value-of select="count($fichier/skosxl:Label)"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2008/05/skos-xl#Label']]">
<xsl:value-of select="count($fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2008/05/skos-xl#Label']])"/>
</xsl:when>
</xsl:choose> Labels (skosxl). [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skosxl:Label/*[generate-id()=generate-id(key('LabelElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "skosxl:Label"</td>
<td>Élément utilisé <xsl:value-of select="count(key('LabelElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<xsl:for-each select="$fichier//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2008/05/skos-xl#Label']]/*[generate-id()=generate-id(key('LabelElemByNameRDF', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans "rdf:Description" de type "Label"</td>
<td>Élément utilisé <xsl:value-of select="count(key('LabelElemByNameRDF', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>
<!--<tr class="header">
<th colspan="2"><span>-</span><mark>skosxl:Labels</mark>. La ressource contient <xsl:value-of select="count($fichier/skosxl:Label)"/> "skosxl:Label". [Cliquer ici pour déplier/replier]</th>
</tr>
<xsl:for-each select="$fichier//skosxl:Label/*[generate-id()=generate-id(key('LabelElemByName', concat(name(),'_',@xml:lang))[1])]">
<tr>
<td>Élément <em><xsl:choose>
<xsl:when test="@xml:lang">
<xsl:value-of select="concat(name(),'_',@xml:lang)"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="name()"/>
</xsl:otherwise>
</xsl:choose></em> dans skosxl:Label</td>
<td>Élément utilisé <xsl:value-of select="count(key('LabelElemByName', concat(name(),'_',@xml:lang)))"/> fois.</td>
</tr>
</xsl:for-each>-->
</xsl:if>
</table>
<!-- Nouvelle table : anomalies -->
<xsl:choose>
<xsl:when test="not(.='')">
<h3>Liste d'anomalies du fichier <em>
<xsl:choose>
<xsl:when test="$fichier/skos:ConceptScheme">
<xsl:value-of select="$fichier/skos:ConceptScheme/dc:title[@xml:lang='fr']"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/dc:title[@xml:lang='fr']"/>
</xsl:when>
</xsl:choose>
</em> :</h3>
<input type="text" id="myInput" onkeyup="myFunction()" placeholder="Chercher une anomalie.." title="Saisir un code"></input>
<table id="myTable" class="anomalies">
<thead>
<tr>
<!--<tr class="header">-->
<th>Anomalie</th>
<th>Description</th>
<th>Détails</th>
</tr>
</thead>
<tbody>
<xsl:copy-of select="./*"/>
</tbody>
</table>
<script type="text/javascript" src="js/result_header.js"><xsl:text> </xsl:text></script>
</xsl:when>
<xsl:otherwise>
<h3>Aucune anomalie n'a été détectée au niveau du fichier <em>
<xsl:choose>
<xsl:when test="$fichier/skos:ConceptScheme">
<xsl:value-of select="$fichier/skos:ConceptScheme/dc:title[@xml:lang='fr']"/>
</xsl:when>
<xsl:when test="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]">
<xsl:value-of select="$fichier/rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#ConceptScheme']]/dc:title[@xml:lang='fr']"/>
</xsl:when>
</xsl:choose>
</em>.</h3>
</xsl:otherwise>
</xsl:choose>
<script>
// tell the embed parent frame the height of the content
//<![CDATA[
if (window.parent && window.parent.parent){
window.parent.parent.postMessage(["resultsFrame", {
height: document.body.getBoundingClientRect().height,
slug: "7ty3b"
}], "*")
}
//]]>
// always overwrite window.name, in case users try to set it manually
window.name = "result"
</script>
</body>
</html>
</xsl:template>
<!-- ==========================================================================================================================
skos:Concept
=============================================================================================================================-->
<xsl:template match="skos:Concept">
<xsl:variable name="ID" select="@rdf:about"/>
<!--contrôle d'unicité de l'identifiant -->
<xsl:choose>
<xsl:when test="following::skos:Concept[@rdf:about=$ID]">
<xsl:variable name="id">
<xsl:value-of select="following::skos:Concept[@rdf:about=$ID]/@rdf:about"/>
</xsl:variable>
<xsl:variable name="pref">
<xsl:value-of select="following::skos:Concept[@rdf:about=$ID]/skos:prefLabel[@xml:lang='fr'][1] | following::skos:Concept[@rdf:about=$ID]/rdfs:label[@xml:lang='fr'][1]"/>
</xsl:variable>
<tr>
<td class="A">D-Id</td>
<td >Doublon au niveau des identifiants (uri) de concepts</td>
<td>
<xsl:text>Les concepts </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$id"/>
<!-- <xsl:value-of select="concat(translate($fichier/skos:ConceptScheme/dc:title[@xml:lang='fr'], ' ', '_'),'.html#', $id)"/> -->
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> et </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$id"/>
<!-- <xsl:value-of select="concat(translate($fichier/skos:ConceptScheme/dc:title[@xml:lang='fr'], ' ', '_'),'.html#', $id)"/> -->
</xsl:attribute>
<xsl:value-of select="$pref"/>
</a>
<xsl:text> ont le même identifiant.</xsl:text>
</td>
<!-- <td>Les concepts <xsl:value-of select="concat(' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/> et <xsl:value-of select="concat(' [', $pref, ']')"/> ont le même identifiant : <xsl:value-of select="$id"/> </td>-->
<!--<td>
<xsl:value-of select="concat($ID, ' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>
<td>
<xsl:value-of select="concat($id, ' [', $pref, ']')"/>
</td>-->
</tr>
</xsl:when>
<xsl:otherwise>
<!-- <tr>
<td class="AV">C0</td>
<td >Contrôle d'unicité des identifiants</td>
<td>Contrôle OK.</td>
</tr>-->
</xsl:otherwise>
</xsl:choose>
<!--URI mal formé-->
<!-- <xsl:for-each select="child::*">-->
<xsl:for-each select="self::node()|node()">
<xsl:if test="contains(@*, '%20')">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (espace) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., '%20')]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $newline)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (retour à la ligne) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $newline)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $apos)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (apostrophe) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $apos)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $quot)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (double quotes) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $quot)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $crochetG)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (crochet gauche) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $crochetG)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $crochetD)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (crochet droit) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $crochetD)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $carriageReturn)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (retour chariot) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $carriageReturn)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $tab)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (tabulation) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $tab)]"/>).</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--contrôle d'unicité des préférentiels pour un même concept -->
<!-- <xsl:for-each select="skos:prefLabel">
<xsl:variable name="lang" select="@xml:lang"/>
<!-\- <xsl:if test="count(skos:prefLabel[@xml:lang=following-sibling::skos:prefLabel/@xml:lang]) > 1">
<xsl:variable name="lang" select="skos:prefLabel[@xml:lang=following-sibling::skos:prefLabel/@xml:lang]/@xml:lang"/>
<xsl:for-each select="skos:prefLabel[@xml:lang=following-sibling::skos:prefLabel/@xml:lang]"> -\->
<xsl:if test="$lang=following-sibling::skos:prefLabel/@xml:lang">
<tr>
<td class="A">NP</td>
<td >Plusieurs préférentiels d'une même langue pour un même concept </td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente plusieurs préférentiels d'une même langue (</xsl:text>
<xsl:value-of select="$lang"/>
<xsl:text>).</xsl:text>
</td>
</tr>
</xsl:if>
<!-\-</xsl:for-each>
</xsl:if>-\->
</xsl:for-each>-->
<!-- test balises vides -->
<xsl:for-each select="skos:prefLabel | skos:altLabel | skos:hiddenLabel | skos:definition | skos:note | skos:scopeNote | skos:historyNote | skos:editorialNote | skos:example |
inist:semCategory | inist:domain | tps:subjectField | tps:semCategory | tps:applicationSubset | dc:identifier |
dcterms:identifier | dcterms:bibliographicalCitation | dcterms:source">
<xsl:if test=".=''">
<tr>
<td class="E">E-0</td>
<td>Propriété vide</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="../skos:prefLabel[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']">
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="../@rdf:about"/>
</xsl:otherwise>
</xsl:choose>
</a>
<xsl:text> présente une propriété (</xsl:text>
<xsl:value-of select="name(.)"/>
<xsl:text>) vide.</xsl:text>
</td>
<!-- <td>
<xsl:value-of select="concat(../@rdf:about, ' [', ../skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
</xsl:for-each>
<!-- test attributs vides -->
<xsl:for-each select="./*">
<xsl:if test="@*=''">
<tr>
<td class="E">@-0</td>
<td>Attribut vide</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente un attribut vide (</xsl:text>
<xsl:value-of select="name(@*)"/>
<xsl:text>) au niveau de la propriété : </xsl:text>
<xsl:value-of select="name(.)"/>
<xsl:text>.</xsl:text>
</td>
<!-- <td>
<xsl:value-of select="concat(../@rdf:about, ' [', ../skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
</xsl:for-each>
<!--RELATIONS-->
<!--test TA = TG -->
<xsl:if test="skos:related/@rdf:resource=skos:broader/@rdf:resource">
<tr>
<td class="A">R-A1</td>
<td>Conflit au niveau des relations : concept associé = concept générique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une anomalie au niveau des relations : un même concept est à la fois concept associé et concept générique du concept courant.</xsl:text>
</td>
<!-- <td>
<xsl:value-of select="concat(@rdf:about, ' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
<!--test de reflexivité : pref=broader -->
<xsl:if test="@rdf:about=skos:broader/@rdf:resource">
<tr>
<td class="A">R-FX1</td>
<td>Relation hiérarchique reflexive</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une relation hiérarchique reflexive : il est concept générique de lui-même.</xsl:text>
</td>
<!--<td>
<xsl:value-of select="concat(@rdf:about, ' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
<!--test de reflexivité : pref=related -->
<xsl:if test="@rdf:about=skos:related/@rdf:resource">
<tr>
<td class="A">R-FX2</td>
<td>Relation associative reflexive</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une relation associative reflexive : il est concept associé de lui-même.</xsl:text>
</td>
<!--<td>
<xsl:value-of select="concat(@rdf:about, ' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
<!--test de boucle : narrower=broader -->
<xsl:if test="skos:broader/@rdf:resource=skos:narrower/@rdf:resource">
<tr>
<td class="A">R-B3</td>
<td>Boucle : concept spécifique = concept générique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une anomalie au niveau des relations : un concept est à la fois concept spécifique et concept générique du concept courant.</xsl:text>
</td>
<!--<td>
<xsl:value-of select="concat(@rdf:about, ' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
<!--test conflit à 3 au niveau des relations associatives et hiérarchiques -->
<xsl:for-each select="skos:related">
<xsl:call-template name="Rel31">
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriRT">
<xsl:value-of select="@rdf:resource"/>
</xsl:with-param>
</xsl:call-template>
</xsl:for-each>
<!-- 2ème test conflit à 3 au niveau des relations associatives et hiérarchiques -->
<xsl:call-template name="Rel32">
<xsl:with-param name="uriConcept" select="@rdf:about"/>
<xsl:with-param name="prefFre" select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</xsl:call-template>
<!--test concept cible inexistant-->
<xsl:for-each select="skos:related | skos:broader | skos:narrower">
<xsl:call-template name="Rel">
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uri">
<xsl:value-of select="@rdf:resource"/>
</xsl:with-param>
</xsl:call-template>
</xsl:for-each>
<!--test TS = TA -->
<xsl:if test="skos:related/@rdf:resource=skos:narrower/@rdf:resource">
<tr>
<td class="A">R-A2</td>
<td>Conflit au niveau des relations : concept associé = concept spécifique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une anomalie au niveau des relations : un concept est à la fois concept spécifique et concept associé du concept courant.</xsl:text>
</td>
<!-- <td>
<xsl:value-of select="concat(@rdf:about, ' [', skos:prefLabel[@xml:lang='fr'][1], ']')"/>
</td>-->
</tr>
</xsl:if>
<!-- test symétrie des TA -->
<xsl:for-each select="skos:related/@rdf:resource">
<xsl:call-template name="TA">
<xsl:with-param name="thisTA">
<xsl:value-of select="."/>
</xsl:with-param>
<xsl:with-param name="thisAbout">
<xsl:value-of select="../../@rdf:about"/>
</xsl:with-param>
</xsl:call-template>
</xsl:for-each>
<!-- problème au niveau de skos:inScheme-->
<xsl:if test="not(skos:inScheme/@rdf:resource)">
<tr>
<td class="A">CS-0</td>
<td>Absence de rattachement du concept à la ressource</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> n'est pas rattaché à la ressource via la propriété "skos:inScheme".</xsl:text>
</td>
<!-- <td>
<xsl:value-of select="@rdf:about"/>
</td>-->
</tr>
</xsl:if>
<!--skos:inScheme différent de l'uri de la ressource-->
<xsl:if test="not($uriRessource='') and not(skos:inScheme/@rdf:resource='')">
<xsl:if test="not(skos:inScheme[@rdf:resource=$uriRessource])">
<tr>
<td class="A">CS-3</td>
<td>Incohérence au niveau de l'identifiant de la ressource</td>
<td>
<xsl:text>Le contenu (</xsl:text>
<xsl:value-of select="skos:inScheme/@rdf:resource"/>
<xsl:text>) de l'attribut "rdf:resource" de la propriété "skos:inScheme" du concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> est différent de l'identifiant de la ressource (</xsl:text>
<xsl:value-of select="$uriRessource"/>
<xsl:text>).</xsl:text>
</td>
<!-- <td>
<xsl:value-of select="@rdf:about"/>
</td>-->
</tr>
</xsl:if>
</xsl:if>
<!--pref absent pour une des langues de la ressource-->
<xsl:variable name="languesPref">
<xsl:for-each select="distinct-values(skos:prefLabel/@xml:lang | rdfs:label/@xml:lang)">
<xsl:sort select="."/>
<lng>
<xsl:value-of select="."/>
</lng>
</xsl:for-each>
</xsl:variable>
<!-- <xsl:text>langues des pref : </xsl:text>-->
<xsl:choose>
<xsl:when test="$languesPref = $languesRessource">
<!-- <tr>
<td class="C">XX OK <xsl:text>il existe un pref pour toutes les langues de la ressource</xsl:text></td>
<td>
</td>
<td>
</td>
</tr>-->
</xsl:when>
<xsl:otherwise>
<tr>
<td class="A">LP-0</td>
<td>Préférentiel absent pour une des langues de la ressource</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="skos:prefLabel[@xml:lang='fr'] | rdfs:label[@xml:lang='fr']">
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</xsl:when>
<xsl:otherwise>
<xsl:choose>
<xsl:when test="skos:prefLabel[@xml:lang='en'] | rdfs:label[@xml:lang='en']">
<xsl:value-of select="skos:prefLabel[@xml:lang='en'][1] | rdfs:label[@xml:lang='en'][1]"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="@rdf:about"/>
</xsl:otherwise>
</xsl:choose>
</xsl:otherwise>
</xsl:choose>
</a>
<xsl:text> n' a pas de préférentiel "</xsl:text>
<xsl:value-of select="$languesRessource/lng[not(.=$languesPref/lng)]"/>
<xsl:text>".</xsl:text>
</td>
</tr>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- ===================================================================================================================================================
rdf:Description type=Concept
======================================================================================================================================================
-->
<xsl:template match="rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept']]">
<xsl:variable name="ID" select="@rdf:about"/>
<!--contrôle d'unicité de l'identifiant -->
<xsl:choose>
<xsl:when test="following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$ID]">
<xsl:variable name="id">
<xsl:value-of select="following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$ID]/@rdf:about"/>
</xsl:variable>
<xsl:variable name="pref">
<xsl:value-of select="following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$ID]/skos:prefLabel[@xml:lang='fr'][1]
| following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$ID]/rdfs:label[@xml:lang='fr'][1] "/>
</xsl:variable>
<tr>
<td class="A">D-Id</td>
<td >Doublon au niveau des identifiants (uri) de concepts</td>
<td>
<xsl:text>Les concepts </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$id"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> et </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$id"/>
</xsl:attribute>
<xsl:value-of select="$pref"/>
</a>
<xsl:text> ont le même identifiant.</xsl:text>
</td>
</tr>
</xsl:when>
<xsl:otherwise>
</xsl:otherwise>
</xsl:choose>
<!--URI mal formé-->
<!-- <xsl:for-each select="child::*">-->
<xsl:for-each select="self::node()|node()">
<xsl:if test="contains(@*, '%20')">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (espace) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., '%20')]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $newline)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (retour à la ligne) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $newline)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $apos)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (apostrophe) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $apos)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $quot)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (double quotes) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $quot)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $crochetG)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (crochet gauche) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $crochetG)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $crochetD)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (crochet droit) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $crochetD)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $carriageReturn)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (retour chariot) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $carriageReturn)]"/>).</td>
</tr>
</xsl:if>
<xsl:if test="contains(@*, $tab)">
<tr>
<td class="A">URI/IRI</td>
<td >Un URI/IRI contient un caractère non autorisé</td>
<td>Un URI/IRI du concept <a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'] | ../dc:title[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']"/></a> contient un caractère non autorisé (tabulation) au niveau de l'élément "<xsl:value-of select="name()"/>" (<xsl:value-of select="@*[contains(., $tab)]"/>).</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- test balises vides -->
<xsl:for-each select="skos:prefLabel | skos:altLabel | skos:hiddenLabel | skos:definition | skos:note | skos:scopeNote | skos:historyNote | skos:editorialNote | skos:example |
inist:semCategory | inist:domain | tps:subjectField | tps:semCategory | tps:applicationSubset | dc:identifier |
dcterms:identifier | dcterms:bibliographicalCitation | dcterms:source">
<xsl:if test=".=''">
<tr>
<td class="E">E-0</td>
<td>Propriété vide</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="../skos:prefLabel[@xml:lang='fr'] | ../rdfs:label[@xml:lang='fr']">
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="../@rdf:about"/>
</xsl:otherwise>
</xsl:choose>
</a>
<xsl:text> présente une propriété (</xsl:text>
<xsl:value-of select="name(.)"/>
<xsl:text>) vide.</xsl:text>
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- test attributs vides -->
<xsl:for-each select="./*">
<xsl:if test="@*=''">
<tr>
<td class="E">@-0</td>
<td>Attribut vide</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="../@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente un attribut vide (</xsl:text>
<xsl:value-of select="name(@*)"/>
<xsl:text> au niveau de la propriété : </xsl:text>
<xsl:value-of select="name(.)"/>
<xsl:text>).</xsl:text>
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--RELATIONS-->
<!--test TA = TG -->
<xsl:if test="skos:related/@rdf:resource=skos:broader/@rdf:resource">
<tr>
<td class="A">R-A1</td>
<td>Conflit au niveau des relations : concept associé = concept générique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une anomalie au niveau des relations : un même concept est à la fois concept associé et concept générique du concept courant.</xsl:text>
</td>
</tr>
</xsl:if>
<!--test de boucle : pref=broader -->
<xsl:if test="@rdf:about=skos:broader/@rdf:resource">
<tr>
<td class="A">R-B1</td>
<td>Boucle : un concept est générique de lui-même</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une boucle : il est concept générique de lui-même.</xsl:text>
</td>
</tr>
</xsl:if>
<!--test de boucle : pref=related -->
<xsl:if test="@rdf:about=skos:related/@rdf:resource">
<tr>
<td class="A">R-B2</td>
<td>Boucle : un concept est associé à lui-même</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une boucle : il est concept associé de lui-même.</xsl:text>
</td>
</tr>
</xsl:if>
<!--test de boucle : narrower=broader -->
<xsl:if test="skos:broader/@rdf:resource=skos:narrower/@rdf:resource">
<tr>
<td class="A">R-B3</td>
<td>Boucle : concept spécifique = concept générique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une anomalie au niveau des relations : un concept est à la fois concept spécifique et concept générique du concept courant.</xsl:text>
</td>
</tr>
</xsl:if>
<!--test conflit à 3 au niveau des relations associatives et hiérarchiques -->
<xsl:for-each select="skos:related">
<xsl:call-template name="Rel312">
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uriRT">
<xsl:value-of select="@rdf:resource"/>
</xsl:with-param>
</xsl:call-template>
</xsl:for-each>
<!-- 2ème test conflit à 3 au niveau des relations associatives et hiérarchiques -->
<xsl:call-template name="Rel322">
<xsl:with-param name="uriConcept" select="@rdf:about"/>
<xsl:with-param name="prefFre" select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</xsl:call-template>
<!--test concept cible inexistant-->
<xsl:for-each select="skos:related | skos:broader | skos:narrower">
<xsl:call-template name="Rel2">
<xsl:with-param name="uriConcept" select="../@rdf:about"/>
<xsl:with-param name="prefFre" select="../skos:prefLabel[@xml:lang='fr'][1] | ../rdfs:label[@xml:lang='fr'][1]"/>
<xsl:with-param name="uri">
<xsl:value-of select="@rdf:resource"/>
</xsl:with-param>
</xsl:call-template>
</xsl:for-each>
<!--test TS = TA -->
<xsl:if test="skos:related/@rdf:resource=skos:narrower/@rdf:resource">
<tr>
<td class="A">R-A2</td>
<td>Conflit au niveau des relations : concept associé = concept spécifique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> présente une anomalie au niveau des relations : un concept est à la fois concept spécifique et concept associé du concept courant.</xsl:text>
</td>
</tr>
</xsl:if>
<!-- test symétrie des TA -->
<xsl:for-each select="skos:related/@rdf:resource">
<xsl:call-template name="TA">
<xsl:with-param name="thisTA">
<xsl:value-of select="."/>
</xsl:with-param>
<xsl:with-param name="thisAbout">
<xsl:value-of select="../../@rdf:about"/>
</xsl:with-param>
</xsl:call-template>
</xsl:for-each>
<!-- problème au niveau de skos:inScheme-->
<xsl:if test="not(skos:inScheme/@rdf:resource)">
<tr>
<td class="A">SC-0</td>
<td>Absence de rattachement du concept à la ressource</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> n'est pas rattaché à la ressource via la propriété "skos:inScheme".</xsl:text>
</td>
</tr>
</xsl:if>
<!--skos:inScheme différent de l'uri de la ressource-->
<xsl:if test="not($uriRessource='') and not(skos:inScheme/@rdf:resource='')">
<xsl:if test="not(skos:inScheme[@rdf:resource=$uriRessource])">
<tr>
<td class="A">CS-3</td>
<td>Incohérence au niveau de l'identifiant de la ressource</td>
<td>
<xsl:text>Le contenu (</xsl:text>
<xsl:value-of select="skos:inScheme/@rdf:resource"/>
<xsl:text>) de l'attribut "rdf:resource" de la propriété "skos:inScheme" du concept [</xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text>] est différent de l'identifiant de la ressource (</xsl:text>
<xsl:value-of select="$uriRessource"/>
<xsl:text>).</xsl:text>
</td>
</tr>
</xsl:if>
</xsl:if>
<!--pref absent pour une des langues de la ressource-->
<xsl:variable name="languesPref">
<xsl:for-each select="distinct-values(skos:prefLabel/@xml:lang | rdfs:label/@xml:lang)">
<xsl:sort select="."/>
<lng>
<xsl:value-of select="."/>
</lng>
</xsl:for-each>
</xsl:variable>
<xsl:choose>
<xsl:when test="$languesPref = $languesRessource">
</xsl:when>
<xsl:otherwise>
<tr>
<td class="A">LP-0</td>
<td>Préférentiel absent pour une des langues de la ressource</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="skos:prefLabel[@xml:lang='fr'] | rdfs:label[@xml:lang='fr']">
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</xsl:when>
<xsl:otherwise>
<xsl:choose>
<xsl:when test="skos:prefLabel[@xml:lang='en'] | rdfs:label[@xml:lang='en']">
<xsl:value-of select="skos:prefLabel[@xml:lang='en'][1] | rdfs:label[@xml:lang='en'][1]"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="@rdf:about"/>
</xsl:otherwise>
</xsl:choose>
</xsl:otherwise>
</xsl:choose>
</a>
<xsl:text> n' a pas de préférentiel "</xsl:text>
<xsl:value-of select="$languesRessource/lng[not(.=$languesPref/lng)]"/>
<xsl:text>".</xsl:text>
</td>
</tr>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!--===============================================================================================================================
relation TA pour skos:Concept
================================================================================================================================
-->
<xsl:template name="TA">
<xsl:param name="thisTA"/>
<xsl:param name="thisAbout"/>
<!-- si l'URI du TA est égal à l'URI d'un concept -->
<xsl:if test="following::skos:Concept[@rdf:about=$thisTA]">
<xsl:choose>
<!-- si, en plus, ce concept a lui-même un TA qui a un URI identique à celui du concept de départ, on ne fait rien (la relation est symétrique)-->
<xsl:when test="following::skos:Concept[@rdf:about=$thisTA]/skos:related[@rdf:resource=$thisAbout]">
</xsl:when>
<!-- dans le cas contraire, la relation n'est pas symétrique -->
<xsl:otherwise>
<tr>
<td class="C">R-NS</td>
<td>Relation d'association non symétrique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$thisAbout"/>
</xsl:attribute>
<xsl:value-of select="../../skos:prefLabel[@xml:lang='fr'][1] | ../../rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> est associé au concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$thisTA"/>
</xsl:attribute>
<xsl:value-of select="following::skos:Concept[@rdf:about=$thisTA]/skos:prefLabel[@xml:lang='fr'][1]"/>
</a>
<xsl:text> mais pas l'inverse. Vous pouvez utiliser le service "Corriger les anomalies de symétrie des concepts associés dans un fichier SKOS/RDF-XML" pour y remédier.</xsl:text>
</td>
</tr>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
</xsl:template>
<!--===============================================================================================================================
relation TA pour rdf:Description
================================================================================================================================
-->
<xsl:template name="TA2">
<xsl:param name="thisTA"/>
<xsl:param name="thisAbout"/>
<!-- si l'URI du TA est égal à l'URI d'un concept -->
<xsl:if test="following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$thisTA]">
<xsl:choose>
<!-- si, en plus, ce concept a lui-même un TA qui a un URI identique à celui du concept de départ, on ne fait rien (la relation est symétrique)-->
<xsl:when test="following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$thisTA]/skos:related[@rdf:resource=$thisAbout]">
</xsl:when>
<!-- dans le cas contraire, la relation n'est pas symétrique -->
<xsl:otherwise>
<tr>
<td class="C">R-NS</td>
<td>Relation d'association non symétrique</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$thisAbout"/>
</xsl:attribute>
<xsl:value-of select="../../skos:prefLabel[@xml:lang='fr'][1]"/>
</a>
<xsl:text> est associé au concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$thisTA"/>
</xsl:attribute>
<xsl:value-of select="following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$thisTA]/skos:prefLabel[@xml:lang='fr'][1]
| following::rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$thisTA]/rdfs:label[@xml:lang='fr'][1]"/>
</a>
<xsl:text> mais pas l'inverse. Vous pouvez utiliser le service "Corriger les anomalies de symétrie des concepts associés dans un fichier SKOS/RDF-XML" pour y remédier.</xsl:text>
</td>
</tr>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
</xsl:template>
<!--============================================================================================================================
relations cibles pour skos:Concept
=============================================================================================================================-->
<xsl:template name="Rel">
<xsl:param name="uri"/>
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<!-- si aucun concept n'a cet uri-->
<xsl:if test="not(//skos:Concept[@rdf:about=$uri])">
<tr>
<td class="C">R-0</td>
<td>Relation vers concept inexistant</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> est en relation avec un concept [</xsl:text>
<xsl:value-of select="$uri"/>
<xsl:text>] absent de la ressource. Créer ce concept ou supprimer la relation.</xsl:text>
</td>
</tr>
</xsl:if>
</xsl:template>
<!--============================================================================================================================
relations cibles pour rdf:Description
=============================================================================================================================-->
<xsl:template name="Rel2">
<xsl:param name="uri"/>
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<!-- si aucun concept n'a cet uri-->
<!-- <xsl:if test="not(//rdf:Description[rdf:type[@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'] and @rdf:about=$uri])">-->
<xsl:if test="not(//rdf:Description[@rdf:about=$uri])">
<tr>
<td class="C">R-0</td>
<td>Relation vers concept inexistant</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> est en relation avec un concept [</xsl:text>
<xsl:value-of select="$uri"/>
<xsl:text>] absent de la ressource. Créer ce concept ou supprimer la relation.</xsl:text>
</td>
</tr>
</xsl:if>
</xsl:template>
<!--============================================================================================================================
clash 29 d'un skos:Concept
=============================================================================================================================-->
<xsl:template name="Rel31">
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<xsl:param name="uriRT"/>
<!-- recherche des narrowers de uriConcept (concept A dans clash 29)-->
<xsl:for-each select="//skos:Concept[skos:broader/@rdf:resource=$uriConcept]">
<xsl:variable name="uriNT" select="@rdf:about"/>
<xsl:variable name="termeNT" select="skos:prefLabel[@xml:lang='fr'][1]"/>
<!--recherche d'un concept dont l'uri est celui du RT et le générique est un des NT du premier concept-->
<xsl:if test="//skos:Concept[@rdf:about=$uriRT and skos:broader/@rdf:resource=$uriNT]">
<!-- <tr>
<td class="A">R-31</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRT"/>
</xsl:attribute>
<xsl:call-template name="pref">
<xsl:with-param name="uri" select="$uriRT"/>
</xsl:call-template>
</a>
<xsl:text> ne peut pas être un concept spécifique du concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a><xsl:text> car il est associé au concept générique </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> de ce dernier.</xsl:text>
</td>
</tr>-->
<!-- <tr>
<td class="A">R-31</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> ne peut pas être un concept générique du concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRT"/>
</xsl:attribute>
<xsl:call-template name="pref">
<xsl:with-param name="uri" select="$uriRT"/>
</xsl:call-template>
</a><xsl:text> car ce dernier est associé au concept générique </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> du premier.</xsl:text>
</td>
</tr>-->
<tr>
<td class="A">R-31</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept A </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> a comme concept spécifique le concept B </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> et comme concept associé le concept C </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRT"/>
</xsl:attribute>
<xsl:call-template name="pref">
<xsl:with-param name="uri" select="$uriRT"/>
</xsl:call-template>
</a><xsl:text>. De ce fait, le concept C ne peut donc pas être un concept spécifique du concept B car le concept C ne peut pas être lié simultanément au concept A par deux relations disjointes "skos:narrowerTransitive" et "skos:related". Voir détails dans </xsl:text>
<a href="https://www.w3.org/TR/skos-primer/#sectransitivebroader">SKOS-Primer</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
</xsl:template>
<!--============================================================================================================================
clash 29 d'un rdf:Description
=============================================================================================================================-->
<xsl:template name="Rel312">
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<xsl:param name="uriRT"/>
--> <!-- recherche des narrowers de uriConcept-->
<xsl:for-each select="//rdf:Description[skos:broader/@rdf:resource=$uriConcept]">
<xsl:variable name="uriNT" select="@rdf:about"/>
<xsl:variable name="termeNT" select="skos:prefLabel[@xml:lang='fr'][1]"/>
<!--recherche d'un concept dont l'uri est celui du RT et le générique est un des NT du premier concept-->
<xsl:if test="//rdf:Description[@rdf:about=$uriRT and skos:broader/@rdf:resource=$uriNT]">
<tr>
<td class="A">R-31</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept A </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> a comme concept spécifique le concept B </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> et comme concept associé le concept C </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRT"/>
</xsl:attribute>
<xsl:call-template name="pref">
<xsl:with-param name="uri" select="$uriRT"/>
</xsl:call-template>
</a><xsl:text>. De ce fait, le concept C ne peut donc pas être un concept spécifique du concept B car le concept C ne peut pas être lié simultanément au concept A par deux relations disjointes "skos:narrowerTransitive" et "skos:related". Voir détails dans </xsl:text>
<a href="https://www.w3.org/TR/skos-primer/#sectransitivebroader">SKOS-Primer</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
</xsl:template>
<!--============================================================================================================================
clash 27 d'un skos:Concept
=============================================================================================================================-->
<xsl:template name="Rel32">
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<!-- <xsl:param name="uriRT"/>-->
<!-- recherche des narrowers de uriConcept (concept B dans clash 27)-->
<xsl:for-each select="//skos:Concept[skos:broader/@rdf:resource=$uriConcept]">
<xsl:variable name="uriNT" select="@rdf:about"/>
<xsl:variable name="termeNT" select="skos:prefLabel[@xml:lang='fr'][1]"/>
<!-- sélection des TA de ces narrowers -->
<xsl:for-each select="skos:related">
<xsl:variable name="uriRel" select="@rdf:resource"/>
<xsl:variable name="termeRel">
<xsl:value-of select="//skos:Concept[@rdf:about=$uriRel]/skos:prefLabel[@xml:lang='fr'][1]"/>
</xsl:variable>
<!-- <xsl:text>R-XX :</xsl:text>Le concept <xsl:value-of select="$uriConcept"/>[<xsl:value-of select="$prefFre"/>]
est le concept générique du concept <xsl:value-of select="../../@rdf:about"/>[<xsl:value-of select="../skos:prefLabel[@xml:lang='fr'][1]"/>]
qui a un concept associé <xsl:value-of select="@rdf:resource"/>[<xsl:value-of select="$fichier//skos:Concept[@rdf:about=$uriRel]/skos:prefLabel[@xml:lang='fr']"/>].
--> <!-- <xsl:call-template name="Rel4">
<xsl:with-param name="uriRel" select="@rdf:resource"/>
<xsl:with-param name="termeRel">
<xsl:value-of select="//skos:Concept[@rdf:about=$uriRel]/skos:prefLabel[@xml:lang='fr'][1]"/>
</xsl:with-param>
<xsl:with-param name="uriNT" select="$uriNT"/>
<xsl:with-param name="termeNT" select="$termeNT"/>
<xsl:with-param name="prefFre" select="$prefFre"/>
<xsl:with-param name="uriConcept" select="$uriConcept"/>
</xsl:call-template>-->
<xsl:if test="//skos:Concept[@rdf:about=$uriConcept and skos:broader/@rdf:resource=$uriRel]">
<tr>
<td class="A">R-32</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept A </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> a comme concept générique le concept B </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> et comme concept associé le concept C </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRel"/>
</xsl:attribute>
<xsl:value-of select="$termeRel"/>
</a><xsl:text>. De ce fait, le concept B ne peut pas avoir comme concept générique le concept C car ce dernier ne peut pas être lié simultanément au concept A par deux relations disjointes "skos:broaderTransitive" et "skos:related". Voir détails dans </xsl:text>
<a href="https://www.w3.org/TR/skos-primer/#sectransitivebroader">SKOS-Primer</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
</xsl:for-each>
</xsl:template>
<!--============================================================================================================================
suite de Rel32
=============================================================================================================================-->
<!--<xsl:template name="Rel4">
<xsl:param name="uriRel"/>
<xsl:param name="termeRel"/>
<xsl:param name="termeNT"/>
<xsl:param name="prefFre"/>
<xsl:param name="uriNT"/>
<xsl:param name="uriConcept"/>
<xsl:if test="//skos:Concept[skos:broader/@rdf:resource=$uriRel]">
<!-\- <tr>
<td class="C">R-32</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> ne peut pas être un concept spécifique du concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRel"/>
</xsl:attribute>
<xsl:value-of select="$termeRel"/>
</a><xsl:text> car ce dernier est un concept associé à un de ses concepts spécifiques </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
<!-\\- </a>
<xsl:text> lui-même spécifique du concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>-\\->
</a>.
</td>
</tr>-\->
<!-\- <tr>
<td class="A">R-32</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> est un concept spécifique du concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> qui a comme concept associé le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRel"/>
</xsl:attribute>
<xsl:value-of select="$termeRel"/>
</a><xsl:text> ; ce dernier ne peut donc pas être un concept spécifique du premier.</xsl:text>
</td>
</tr> -\->
<tr>
<td class="A">R-32</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept A </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> a comme concept générique le concept B </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> et comme concept associé le concept C </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRel"/>
</xsl:attribute>
<xsl:value-of select="$termeRel"/>
</a><xsl:text>. De ce fait, le concept B ne peut pas avoir comme concept générique le concept C car ce dernier ne peut pas être lié simultanément au concept A par deux relations disjointes "skos:broaderTransitive" et "skos:related". Voir détails dans </xsl:text>
<a href="https://www.w3.org/TR/skos-primer/#sectransitivebroader">SKOS-Primer</a>.
</td>
</tr>
</xsl:if>
</xsl:template>-->
<!--============================================================================================================================
clash 27 d'un rdf:Description
=============================================================================================================================-->
<xsl:template name="Rel322">
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<xsl:param name="uriRT"/>
<!-- recherche des narrowers de uriConcept (concept B dans clash 27)-->
<xsl:for-each select="//rdf:Description[skos:broader/@rdf:resource=$uriConcept]">
<xsl:variable name="uriNT" select="@rdf:about"/>
<xsl:variable name="termeNT" select="skos:prefLabel[@xml:lang='fr'][1]"/>
<!-- sélection des TA de ces narrowers -->
<xsl:for-each select="skos:related">
<xsl:variable name="uriRel" select="@rdf:resource"/>
<xsl:variable name="termeRel">
<xsl:value-of select="//rdf:Description[@rdf:about=$uriRel]/skos:prefLabel[@xml:lang='fr'][1]"/>
</xsl:variable>
<xsl:if test="//rdf:Description[@rdf:about=$uriConcept and skos:broader/@rdf:resource=$uriRel]">
<tr>
<td class="A">R-32</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept A </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> a comme concept générique le concept B </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> et comme concept associé le concept C </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRel"/>
</xsl:attribute>
<xsl:value-of select="$termeRel"/>
</a><xsl:text>. De ce fait, le concept B ne peut pas avoir comme concept générique le concept C car ce dernier ne peut pas être lié simultanément au concept A par deux relations disjointes "skos:broaderTransitive" et "skos:related". Voir détails dans </xsl:text>
<a href="https://www.w3.org/TR/skos-primer/#sectransitivebroader">SKOS-Primer</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
</xsl:for-each>
</xsl:template>
<!--============================================================================================================================
suite de Rel322
=============================================================================================================================-->
<!-- <xsl:template name="Rel42">
<xsl:param name="uriRel"/>
<xsl:param name="termeRel"/>
<xsl:param name="termeNT"/>
<xsl:param name="prefFre"/>
<xsl:param name="uriNT"/>
<xsl:param name="uriConcept"/>
<xsl:if test="//rdf:Description[skos:broader/@rdf:resource=$uriRel]">
<tr>
<td class="A">R-32</td>
<td>Conflit à trois au niveau des relations associatives et hiérarchiques</td>
<td>
<xsl:text>Le concept A </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriNT"/>
</xsl:attribute>
<xsl:value-of select="$termeNT"/>
</a>
<xsl:text> a comme concept générique le concept B </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> et comme concept associé le concept C </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriRel"/>
</xsl:attribute>
<xsl:value-of select="$termeRel"/>
</a><xsl:text>. De ce fait, le concept B ne peut pas avoir comme concept générique le concept C car ce dernier ne peut pas être lié simultanément au concept A par deux relations disjointes "skos:broaderTransitive" et "skos:related". Voir détails dans </xsl:text>
<a href="https://www.w3.org/TR/skos-primer/#sectransitivebroader">SKOS-Primer</a>.
</td>
</tr>
</xsl:if>
</xsl:template>-->
<!-- =================================================================================
unicité des pref
=================================================================================== -->
<xsl:template name="TermUniqueness">
<xsl:param name="uriConcept"/>
<xsl:param name="language"/>
<xsl:param name="term"/>
<xsl:param name="prefFre"/>
<xsl:param name="position"/>
<!-- plusieurs libellés préférentiels d'une même langue au sein du même concept -->
<!-- <xsl:for-each select="//skos:Concept[@rdf:about=$uriConcept and skos:prefLabel[@xml:lang=$language and position() > $position]]">-->
<xsl:for-each select="//skos:Concept[@rdf:about=$uriConcept and count(skos:prefLabel[@xml:lang=$language]) >1]">
<tr>
<td class="A">LP-N1</td>
<td>Plusieurs libellés préférentiels d'une même langue pour un même concept</td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> présente plusieurs libellés préférentiels (</xsl:text>
<xsl:for-each select="skos:prefLabel[@xml:lang=$language]">
<xsl:choose>
<xsl:when test="position()=last()">
<xsl:value-of select="."/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="."/>
<xsl:text> / </xsl:text>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
<xsl:text>) d'une même langue (</xsl:text>
<xsl:value-of select="$language"/>
<xsl:text>).</xsl:text>
</td>
</tr>
</xsl:for-each>
<!-- ======================================rdf:Description=================================================== -->
<xsl:for-each select="//rdf:Description[@rdf:about=$uriConcept and count(skos:prefLabel[@xml:lang=$language]) >1]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LP-N1</td>
<td>Plusieurs libellés préférentiels d'une même langue pour un même concept <xsl:value-of select="@rdf:about"/></td>
<td>
<xsl:text>Le concept </xsl:text>
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>
<xsl:text> présente plusieurs llibellés préférentiels (</xsl:text>
<xsl:for-each select="skos:prefLabel[@xml:lang=$language]">
<xsl:choose>
<xsl:when test="position()=last()">
<xsl:value-of select="."/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="."/>
<xsl:text> / </xsl:text>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
<xsl:text>) d'une même langue (</xsl:text>
<xsl:value-of select="$language"/>
<xsl:text>).</xsl:text>
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- Doublon pref / alt (même langue) au sein du même concept -->
<xsl:for-each select="//skos:Concept[@rdf:about=$uriConcept and skos:altLabel[@xml:lang=$language]=$term ]">
<tr>
<td class="A">LP-LA1</td>
<td>Doublon libellé préférentiel / libellé alternatif au sein du même concept</td>
<!-- <td>Le terme "<xsl:value-of select="$term"/>" est en même temps un libellé préférentiel "<xsl:value-of select="$language"/>" et et un libellé alternatif "<xsl:value-of select="skos:altLabel[@xml:lang=$language and .=$term]/@xml:lang"/>" du concept -->
<td>Le terme "<xsl:value-of select="$term"/>" est en même temps le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") et et un libellé alternatif du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ======================================rdf:Description=================================================== -->
<xsl:for-each select="//rdf:Description[@rdf:about=$uriConcept and skos:altLabel[@xml:lang=$language]=$term ]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LP-LA1</td>
<td>Doublon libellé préférentiel / libellé alternatif au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" est en même temps le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") et et un libellé alternatif du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- doublon pref : hidden (même langue) au sein du même concept -->
<xsl:for-each select="//skos:Concept[@rdf:about=$uriConcept and skos:hiddenLabel[@xml:lang=$language]=$term ]">
<tr>
<td class="A">LP-LC1</td>
<td>Doublon libellé préférentiel / libellé caché au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" est en même temps le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") et et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ======================================rdf:Description=================================================== -->
<xsl:for-each select="//rdf:Description[@rdf:about=$uriConcept and skos:hiddenLabel[@xml:lang=$language]=$term ]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LP-LC1</td>
<td>Doublon libellé préférentiel / libellé caché au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" est en même temps le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") et et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- Libellé préférentiel identique pour deux concepts différents -->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:prefLabel[@xml:lang=$language]=$term]">
<tr>
<td class="A">LP-LP2</td>
<td>Libellé préférentiel identique pour deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") à la fois du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="// rdf:Description[not(@rdf:about=$uriConcept) and skos:prefLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LP-LP2</td>
<td>Libellé préférentiel identique pour deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") à la fois du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--Doublon libellé préférentiel / libellé alternatif entre deux concepts différents -->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:altLabel[@xml:lang=$language]=$term]">
<tr>
<td class="A">LP-LA2</td>
<td>Doublon libellé préférentiel / libellé alternatif entre deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé alternatif du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="//rdf:Description[not(@rdf:about=$uriConcept) and skos:altLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LP-LA2</td>
<td>Doublon libellé préférentiel / libellé alternatif entre deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est le libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé alternatif du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--Doublon libellé préférentiel / libellé caché entre deux concepts différents -->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:hiddenLabel[@xml:lang=$language]=$term]">
<tr>
<td class="E">LP-LC2</td>
<td>Doublon libellé préférentiel / libellé caché entre deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="//rdf:Description[not(@rdf:about=$uriConcept) and skos:hiddenLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="E">LP-LC2</td>
<td>Doublon libellé préférentiel / libellé caché entre deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé préférentiel (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
</xsl:template>
<!-- =================================================================================
unicité des synos
=================================================================================== -->
<xsl:template name="TermUniqueness2">
<xsl:param name="uriConcept"/>
<xsl:param name="language"/>
<xsl:param name="term"/>
<xsl:param name="prefFre"/>
<xsl:param name="position"/>
<!-- synonyme non unique au sein du mêlme concept -->
<xsl:for-each select="//skos:Concept[@rdf:about=$uriConcept and skos:altLabel[@xml:lang=$language and position() > $position]=$term ]">
<tr>
<td class="A">LA-LA1</td>
<td>Doublon au niveau des libellés alternatifs au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" apparaît plusieurs fois comme libellé alternatif (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="//rdf:Description[@rdf:about=$uriConcept and skos:altLabel[@xml:lang=$language and position() > $position]=$term ]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LA-LA1</td>
<td>Doublon au niveau des libellés alternatifs au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" apparaît plusieurs fois comme libellé alternatif (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- Libellé alternatif identique pour deux concepts différents -->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:altLabel[@xml:lang=$language]=$term]">
<tr>
<td class="A">LA-LA2</td>
<td>Libellé alternatif identique pour deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé alternatif (code langue : "<xsl:value-of select="$language"/>") à la fois du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:altLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LA-LA2</td>
<td>Libellé alternatif identique pour deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé alternatif (code langue : "<xsl:value-of select="$language"/>") à la fois du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--Doublon libellé alternatif / libellé caché au sein du même concept -->
<xsl:for-each select="//skos:Concept[@rdf:about=$uriConcept and skos:hiddenLabel[@xml:lang=$language]=$term ]">
<tr>
<td class="A">LA-LC1</td>
<td>Doublon libellé alternatif / libellé caché au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" est en même temps un libellé alternatif (code langue : "<xsl:value-of select="$language"/>") et et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ======================================rdf:Description=========================================== -->
<xsl:for-each select="//rdf:Description[@rdf:about=$uriConcept and skos:hiddenLabel[@xml:lang=$language]=$term ]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">LA-LC1</td>
<td>Doublon libellé alternatif / libellé caché au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" est en même temps un libellé alternatif (code langue : "<xsl:value-of select="$language"/>") et et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- Doublon Libellé alternatif / libellé caché entre deux concepts différents -->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:hiddenLabel[@xml:lang=$language]=$term]">
<tr>
<td class="E">LA-LC2</td>
<td>Doublon libellé alternatif / libellé caché entre deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé alternatif (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:hiddenLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="E">LA-LC2</td>
<td>Doublon libellé alternatif / libellé caché entre deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé alternatif (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et un libellé caché du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!-- <xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:prefLabel[@xml:lang=$language]=$term]">
<tr>
<td class="A">DBL22</td>
<td>Libellé alternatif non unique</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé alternatif "<xsl:value-of select="$language"/>" du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé préférentiel "<xsl:value-of select="skos:prefLabel[@xml:lang=$language and .=$term]/@xml:lang"/>"
du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>. </td>
</tr>
</xsl:for-each>
<!-\- ===========================rdf:Description ==============================================-\->
<xsl:for-each select="//rdf:Description[not(@rdf:about=$uriConcept) and skos:prefLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="A">DBL22</td>
<td>Libellé alternatif non unique</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé alternatif "<xsl:value-of select="$language"/>" du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé préférentiel "<xsl:value-of select="skos:prefLabel[@xml:lang=$language and .=$term]/@xml:lang"/>"
du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>. </td>
</tr>
</xsl:if>
</xsl:for-each>-->
</xsl:template>
<!-- =================================================================================
unicité des hiddens
=================================================================================== -->
<xsl:template name="TermUniqueness3">
<xsl:param name="uriConcept"/>
<xsl:param name="language"/>
<xsl:param name="term"/>
<xsl:param name="prefFre"/>
<xsl:param name="position"/>
<!--terme caché non unique au sein du mêlme concept -->
<xsl:if test="//skos:Concept[@rdf:about=$uriConcept and skos:hiddenLabel[@xml:lang=$language and position() > $position]=$term ]">
<tr>
<td class="E">LC-LC1</td>
<td>Doublon au niveau des libellés cachés au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" apparaît plusieurs fois comme libellé caché (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:if>
<!-- ==============================================rdf:Description====================================================== -->
<xsl:for-each select="//rdf:Description[@rdf:about=$uriConcept and skos:hiddenLabel[@xml:lang=$language and position() > $position ]=$term ]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="E">LC-LC1</td>
<td>Doublon au niveau des libellés cachés au sein du même concept</td>
<td>Le terme "<xsl:value-of select="$term"/>" apparaît plusieurs fois comme libellé caché (code langue : "<xsl:value-of select="$language"/>") du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--Libellé caché identique pour deux concepts différents -->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:hiddenLabel[@xml:lang=$language]=$term]">
<tr>
<td class="E">LC-LC2</td>
<td>Libellé caché identique pour deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé caché (code langue : "<xsl:value-of select="$language"/>") à la fois du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-- ===========================rdf:Description ==============================================-->
<xsl:for-each select="//rdf:Description[not(@rdf:about=$uriConcept) and skos:hiddenLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="E">LC-LC2</td>
<td>Libellé caché identique pour deux concepts différents</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé caché (code langue : "<xsl:value-of select="$language"/>") à la fois du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1] | rdfs:label[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>
<!--<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:altLabel[@xml:lang=$language]=$term]">
<tr>
<td class="E">DBL32</td>
<td>Libellé caché non unique</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé caché "<xsl:value-of select="$language"/>" du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé alternatif "<xsl:value-of select="skos:altLabel[@xml:lang=$language and .=$term]/@xml:lang"/>"
du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:for-each>
<!-\- ===========================rdf:Description ==============================================-\->
<xsl:for-each select="//skos:Concept[not(@rdf:about=$uriConcept) and skos:altLabel[@xml:lang=$language]=$term]">
<xsl:if test="rdf:type/@rdf:resource='http://www.w3.org/2004/02/skos/core#Concept'">
<tr>
<td class="E">DBL32</td>
<td>Libellé caché non unique</td>
<td>Le terme "<xsl:value-of select="$term"/>" est un libellé caché "<xsl:value-of select="$language"/>" du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> et et un libellé alternatif "<xsl:value-of select="skos:altLabel[@xml:lang=$language and .=$term]/@xml:lang"/>"
du concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="@rdf:about"/>
</xsl:attribute>
<xsl:value-of select="skos:prefLabel[@xml:lang='fr'][1]"/>
</a>.
</td>
</tr>
</xsl:if>
</xsl:for-each>-->
</xsl:template>
<!-- ===================================================================
orphelins
=======================================================================-->
<!-- <xsl:template name="orphelin">
<xsl:param name="uriConcept"/>
<xsl:param name="prefFre"/>
<xsl:if test="not($fichier//skos:broader[@rdf:resource=$uriConcept])">
<tr>
<td class="A">R-OR</td>
<td>Concept orphelin</td>
<td>Le concept
<a>
<xsl:attribute name="href">
<xsl:value-of select="$uriConcept"/>
</xsl:attribute>
<xsl:value-of select="$prefFre"/>
</a> est orphelin.
</td>
</tr>
</xsl:if>
</xsl:template>-->
<!--
=====================================================================================
pref
=====================================================================================-->
<xsl:template name="pref">
<xsl:param name="uri"/>
<xsl:if test="//skos:Concept[@rdf:about=$uri]">
<xsl:value-of select="//skos:Concept[@rdf:about=$uri]/skos:prefLabel[@xml:lang='fr'][1] | //skos:Concept[@rdf:about=$uri]/rdfs:label[@xml:lang='fr'][1]"/>
</xsl:if>
<xsl:if test="//rdf:Description[@rdf:about=$uri]">
<xsl:value-of select="//rdf:Description[@rdf:about=$uri]/skos:prefLabel[@xml:lang='fr'][1] | //rdf:Description[@rdf:about=$uri]/rdfs:label[@xml:lang='fr'][1]"/>
</xsl:if>
</xsl:template>
<xsl:template name="field">
<tr>
<td>Les champs de la ressource sont (par ordre alphabétique) :
<xsl:value-of select="."/>
</td>
</tr>
</xsl:template>
</xsl:stylesheet>