Skip to content

Commit

Permalink
INSPIRE conformity improvement (#234)
Browse files Browse the repository at this point in the history
* geocat.ch / INSPIRE conformity / Remove enumration extension

iso19139.che extend topic category enumeration and conversion to
ISO19139 does not remove them. Produced XML is invalid with the
following:

```
XML document 'file.xml', record '8698bf0b-fceb-4f0f-989b-111e7c4af0a4': 'Validation failed: 752:87: cvc-enumeration-valid: Value 'planningCadastre_Planning' is not facet-valid with respect to enumeration '[farming, biota, boundaries, climatologyMeteorologyAtmosphere, economy, elevation, environment, geoscientificInformation, health, imageryBaseMapsEarthCover, intelligenceMilitary, inlandWaters, location, oceans, planningCadastre, society, structure, transportation, utilitiesCommunication]'. It must be a value from the enumeration.'.
```

Proposal: Remove all extended values.

* geocat.ch / INSPIRE / Support nilReason in boolean geonetwork/core-geonetwork@9755269.

* geocat.ch / INSPIRE / Backport of geonetwork/core-geonetwork#6617.

* geocat.ch / INSPIRE / ISO19139 conversion / Better conversion of multilingual URLs.

* geocat.ch / INSPIRE / Configure which INSPIRE test suite to run.

* geocat.ch / INSPIRE / Process to improve conformity.

* geocat.ch / INSPIRE / Process to improve conformity.

* geocat.ch / INSPIRE / Configure ETF CC for services. Increase checks in case of slow validation.

* geocat.ch / INSPIRE themes / Migration from Eionet URI to INSPIRE registry.

* geocat.ch / INSPIRE / Improve conformity / Topic category mapping, distributorFormat.

* geocat.ch / INSPIRE conformity / SDS category encoded as Anchor. Backport geonetwork/core-geonetwork#6664. Conformance editing with 3 states conform/not/unknown.

* geocat.ch / INSPIRE conformity tests.

* geocat.ch / INSPIRE / Add thesaurus required for conformity.

* geocat.ch / INSPIRE themes / Migration from Eionet URI to INSPIRE registry.

---------

Co-authored-by: Francois Prunayre <[email protected]>
  • Loading branch information
2 people authored and cmangeat committed Jan 29, 2024
1 parent 6ec67d6 commit dc696a1
Show file tree
Hide file tree
Showing 13 changed files with 5,054 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
exclude-result-prefixes="#all">
<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>

<xsl:variable name="langId"
select="/che:CHE_MD_Metadata/gmd:language/*/@codeListValue"/>


<!-- Some default values -->
<xsl:template match="gmd:metadataStandardName">
<gmd:metadataStandardName>
Expand All @@ -22,6 +26,26 @@
</gmd:metadataStandardVersion>
</xsl:template>

<xsl:template match="che:*[not(@gco:isoType)]" priority="100"/>

<xsl:template match="@xsi:type[.='che:PT_FreeURL_PropertyType']" priority="2">
<xsl:apply-templates mode="url" select=".."/>
</xsl:template>

<xsl:template match="gmd:linkage">
<gmd:linkage>
<gmd:URL>
<xsl:value-of select="(che:LocalisedURL
|*/che:URLGroup/che:LocalisedURL[@locale = $langId]
|gmd:URL
|*/che:URLGroup/che:LocalisedURL[. != ''])[1]"/>
</gmd:URL>
</gmd:linkage>
</xsl:template>

<!-- Remove all non ISO19139 enumeration value. -->
<xsl:template match="gmd:topicCategory[contains(*, '_')]" priority="2"/>

<!-- All profil specific elements should be bypassed -->
<xsl:template match="che:*[not(@gco:isoType)]" priority="2"/>

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0"
xmlns:gco="http://www.isotc211.org/2005/gco"
xmlns:gmd="http://www.isotc211.org/2005/gmd"
exclude-result-prefixes="#all">
<xsl:import href="../iso19139/inflate-metadata.xsl"/>
</xsl:stylesheet>
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,14 @@
<for name="gco:Integer" use="number"/>
<for name="gco:Real" use="number"/>
<for name="gco:Boolean" use="checkbox"/>

<for name="gco:Boolean"
xpath="/che:CHE_MD_Metadata/gmd:dataQualityInfo/gmd:DQ_DataQuality/gmd:report/gmd:DQ_DomainConsistency/gmd:result/gmd:DQ_ConformanceResult/gmd:pass"
use="data-gn-checkbox-with-nilreason">
<directiveAttributes
data-tag-name="gmd:pass"
data-nilreason="eval#@gco:nilReason"
data-labels='{"true": "conformant", "false": "notConformant", "unknown": "notEvaluated"}'/>
</for>

<for name="gco:Date" use="data-gn-date-picker"/>
<for name="gco:DateTime" use="data-gn-date-picker"/>
Expand Down Expand Up @@ -472,6 +479,9 @@
<thesaurus key="external.none.allThesaurus"
transformations="to-iso19139-keyword-as-xlink"
/>
<thesaurus key="external.theme.httpinspireeceuropaeumetadatacodelistSpatialDataServiceCategory-SpatialDataServiceCategory"
transformations="to-iso19139-keyword-as-xlink-with-anchor"
/>
</thesaurusList>
</view>
<view name="advanced">
Expand Down Expand Up @@ -571,6 +581,9 @@
<thesaurus key="external.none.allThesaurus"
transformations="to-iso19139-keyword-as-xlink"
/>
<thesaurus key="external.theme.httpinspireeceuropaeumetadatacodelistSpatialDataServiceCategory-SpatialDataServiceCategory"
transformations="to-iso19139-keyword-as-xlink-with-anchor"
/>
</thesaurusList>
</view>
<view name="bgdi">
Expand Down
Loading

0 comments on commit dc696a1

Please sign in to comment.