Skip to content

Commit

Permalink
Merge pull request #289 from opendata-swiss/geocat
Browse files Browse the repository at this point in the history
Geocat
  • Loading branch information
mispichtig authored Nov 12, 2024
2 parents d55e5ed + 18f9660 commit a053628
Show file tree
Hide file tree
Showing 7 changed files with 140 additions and 11 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.. code-block:: xml
:caption: Mapping of the che:dataModel to dct:conforms to
:emphasize-lines: 9
<che:dataModel xsi:type="che:PT_FreeURL_PropertyType">
<che:PT_FreeURL>
<che:URLGroup>
<che:LocalisedURL locale="#FR">https://models.geo.admin.ch/ASTRA/</che:LocalisedURL>
</che:URLGroup>
</che:PT_FreeURL>
</che:dataModel>
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
.. code-block:: xml
:caption: Mapping of the documentation of all other resources except the first one with protocol ``WWW:LINK``
:emphasize-lines: 3,19,20,21
<gmd:CI_OnlineResource>
<gmd:linkage xsi:type="che:PT_FreeURL_PropertyType">
<gmd:URL>https://swisstopo.admin.ch</gmd:URL>
<che:PT_FreeURL>
<che:URLGroup>
<che:LocalisedURL locale="#DE">https://swisstopo.admin.ch</che:LocalisedURL>
</che:URLGroup>
<che:URLGroup>
<che:LocalisedURL locale="#FR">https://swisstopo.admin.ch</che:LocalisedURL>
</che:URLGroup>
<che:URLGroup>
<che:LocalisedURL locale="#IT">https://swisstopo.admin.ch</che:LocalisedURL>
</che:URLGroup>
<che:URLGroup>
<che:LocalisedURL locale="#EN">https://swisstopo.admin.ch</che:LocalisedURL>
</che:URLGroup>
</che:PT_FreeURL>
</gmd:linkage>
<gmd:protocol>
<gco:CharacterString>WWW:LINK</gco:CharacterString>
</gmd:protocol>
<gmd:name xsi:type="gmd:PT_FreeText_PropertyType">
<gco:CharacterString>Landing Page</gco:CharacterString>
<gmd:PT_FreeText>
<gmd:textGroup>
<gmd:LocalisedCharacterString locale="#DE">Landing Page</gmd:LocalisedCharacterString>
</gmd:textGroup>
</gmd:PT_FreeText>
</gmd:name>
<gmd:description gco:nilReason="missing" xsi:type="gmd:PT_FreeText_PropertyType">
<gco:CharacterString/>
</gmd:description>
<gmd:function>
<gmd:CI_OnLineFunctionCode
codeList="http://standards.iso.org/ittf/PubliclyAvailableStandards/ISO_19139_Schemas/resources/codelist/ML_gmxCodelists.xml#CI_OnLineFunctionCode"
codeListValue="information"/>
</gmd:function>
</gmd:CI_OnlineResource>
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.. code-block:: xml
:caption: Geocat Identifiers for ``dcat:qualifiedRelation``
:emphasize-lines: 4
<gmd:aggregateDataSetIdentifier>
<gmd:MD_Identifier>
<gmd:code>
<gco:CharacterString>73856ca2:f21d:4cc9:90f6:f3e8375555df</gco:CharacterString>
</gmd:code>
</gmd:MD_Identifier>
</gmd:aggregateDataSetIdentifier>
52 changes: 43 additions & 9 deletions source/content/glossar/bibliothek/geocat-mapping.rst
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,15 @@ Mapping to dcat:Dataset
* - :ref:`accrual periodicity <dcat-dataset-accrual-periodicity>`
- :ref:`//gmd:identificationInfo//che:CHE_MD_MaintenanceInformation <geocat-dataset-accrual-periodicity>`
-
* - :ref:`see also <dcat-dataset-see-also>`
- :ref:`//gmd:identificationInfo//gmd:aggregationInfo <geocat-dataset-see-also>`
-
* - :ref:`qualified relation <dcat-dataset-qualified-relation>`
- :ref:`//gmd:identificationInfo//gmd:aggregationInfo <geocat-dataset-qualified-relation>`
-
* - :ref:`documentation <dcat-dataset-documentation>`
- :ref:`//gmd:distributionInfo/gmd:MD_Distribution <geocat-dataset-documentation>`
- new property, depends on gmd:protocol
* - :ref:`conforms to <dcat-dataset-conforms-to>`
- :ref:`//gmd:contentInfo/che:CHE_MD_FeatureCatalogueDescription/che:dataModel <geocat-dataset-conforms-to>`
- new property

.. _iso_19139_che-distribution-mapping:

Expand Down Expand Up @@ -413,19 +419,47 @@ Dataset

.. include:: geocat-examples/dataset-accrual-periodicity.rst

.. _geocat-dataset-see-also:
.. _geocat-dataset-qualified-relation:

``//gmd:identificationInfo//gmd:aggregationInfo`` to ``dcat:qualifiedRelation``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. container:: Mapping

.. include:: geocat-mappings/dataset-qualified-relation.rst

.. toggle-header::
:header: Example for geocat mapping to ``dcat:qualifiedRelation``

.. include:: geocat-examples/dataset-qualified-relation.rst

.. _geocat-dataset-documentation:

``//gmd:distributionInfo/gmd:MD_Distribution`` to ``foaf:page``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. container:: Mapping

.. include:: geocat-mappings/dataset-documentation.rst

.. toggle-header::
:header: Example for geocat mapping to ``foaf:page``

.. include:: geocat-examples/dataset-documentation.rst

.. _geocat-dataset-conforms-to:

``//gmd:identificationInfo//gmd:aggregationInfo`` to ``dct:seeAlso``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
``//che:dataModel//che:LocalisedURL`` to ``dct:conformsTo``
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. container:: Mapping

.. include:: geocat-mappings/dataset-see-also.rst
.. include:: geocat-mappings/dataset-conforms-to.rst

.. toggle-header::
:header: Definition of ``dcat:seeAlso`` in DCAT-AP CH
:header: Example for geocat mapping to ``dct:conformsTo``

.. include:: geocat-examples/dataset-see-also.rst
.. include:: geocat-examples/dataset-conforms-to.rst

.. _iso_19139_che-distribution:

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
:DCAT: :ref:`dct:conformsTo <dcat-dataset-conforms-to>`
:XPATH: ``che:CHEMD_Metadata/gmd:contentInfo/che:CHE_MD_FeatureCatalogueDescription/che:dataModel/``
:Value: ``.//gmd:contentInfo//che:CHE_MD_FeatureCatalogueDescription//che:dataModel/text()``
:Usage Notes:

.. code-block:: xml
:caption: ISO-19139_che XPath for dct:conforms to
.//gmd:contentInfo//che:CHE_MD_FeatureCatalogueDescription//che:dataModel//che:PT_FreeURL//che:URLGroup//che:LocalisedURL[@locale="#DE"]/text()
.//gmd:contentInfo//che:CHE_MD_FeatureCatalogueDescription//che:dataModel//che:PT_FreeURL//che:URLGroup//che:LocalisedURLL[@locale="#FR"]/text()
.//gmd:contentInfo//che:CHE_MD_FeatureCatalogueDescription//che:dataModel//che:PT_FreeURL//che:URLGroup//che:LocalisedURL[@locale="#EN"]/text()
.//gmd:contentInfo//che:CHE_MD_FeatureCatalogueDescription//che:dataModel//che:PT_FreeURL//che:URLGroup//che:LocalisedURL[@locale="#IT"]/text()
.//gmd:contentInfo//che:CHE_MD_FeatureCatalogueDescription//che:dataModel//che:PT_FreeURL//che:URLGroup//che:LocalisedURL/text()
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
:DCAT: :ref:`foaf:page <dcat-dataset-documentation>`
:XPATH: ``//gmd:distributionInfo/gmd:MD_Distribution//gmd:transferOptions//gmd:CI_OnlineResource``
:Protocol: ``WWW:LINK``
:Value: ``.//gmd:linkage/gmd:URL/text()``
:Fallback-Value: ``'.//che:LocalisedURL`` for any language
:Usage Notes: The first resource with WWW:LINK protocol is mapped as dcat:landingPage. All other resources with WWW:LINK protocol are mapped as foaf:page.

.. code-block:: xml
:caption: ISO-19139_che XPath for foaf:page
//gmd:distributionInfo/gmd:MD_Distribution//gmd:transferOptions//gmd:CI_OnlineResource
.. code-block:: xml
:caption: ISO-19139_che XPath for distribution protocol
//gmd:distributionInfo/gmd:MD_Distribution//gmd:transferOptions//gmd:CI_OnlineResource//gmd:protocol
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
:DCAT: :ref:`rdfs:seeAlso <dcat-dataset-see-also>`
:DCAT: :ref:`dcat:qualifiedRelation <dcat-dataset-qualified-relation>`
:XPATH: ``//gmd:identificationInfo//gmd:aggregationInfo//gmd:aggregateDataSetIdentifier/gmd:MD_Identifier``
:Value: ``/gmd:code/gco:CharacterString``
:Mapping of Values: The geocat identifier is mapped to a dct:identifier by attaching ``@<organization-slug>``

.. code-block:: xml
:caption: XPATH for rdfs:seeAlso: all such values are taken
:caption: XPATH for dcat:qualifiedRelation: all such values are taken
//gmd:identificationInfo//gmd:aggregationInfo//gmd:aggregateDataSetIdentifier/gmd:MD_Identifier/gmd:code/gco:CharacterString

0 comments on commit a053628

Please sign in to comment.