dwc/build/terms.tmpl

84 lines
5.4 KiB
Cheetah

{#
This template is NOT used by jekyll, but by the Darwin Core build script
to create the terms/index.md file, which mostly contains html.
#}
# Darwin Core Quick Reference Guide
This document is intended to be an easy-to-read reference of the currently (as of 2023-09-18) recommended terms maintained as part of the [Darwin Core standard](https://www.tdwg.org/standards/dwc/) and is maintained by the [Darwin Core Maintenance Group](https://www.tdwg.org/community/dwc/).
**Need help?** Read more about how to use Darwin Core in the [Darwin Core Questions & Answers site](https://github.com/tdwg/dwc-qa/blob/master/README.md). Still have questions? Submit a new issue (question/problem) to the [dwc-qa issues page in GitHub](https://github.com/tdwg/dwc-qa/issues), or use the [form](https://tinyurl.com/darwin-qa). See the bottom of this document for [how to cite Darwin Core](https://dwc.tdwg.org/terms/#cite-darwin-core)."
**Want to contribute?** For information about how to contribute to the Darwin Core Standard, including how to propose changes, see the [Guidelines for contributing](https://github.com/tdwg/dwc/blob/master/.github/CONTRIBUTING.md).
This page is not part of the standard, but combines the normative term names and definitions with the non-normative comments and examples that are meant to help people to use the terms consistently. Definitions, comments, and examples may include namespace abbreviations (e.g., "dwc:"). These are included to show that the meaning for the word it is attached to very specifically means the term as defined in that namespace. Thus, dwc:Event means Event as defined by Darwin Core at https://dwc.tdwg.org/terms/#event. Capitalized terms that follow a namespace abbreviation, such as dwc:Occurrence, are Darwin Core class terms, which are a special category of terms used to group sets of property terms (terms that being with lower case names that follow the namespace abbreviation, e.g., dwc:eventID) for convenience. Comprehensive metadata for current and obsolete terms in human readable form are found in the document [List of Darwin Core terms](../list/).
Additional [files with just the current term names](https://github.com/tdwg/dwc/tree/master/dist) and a [file with the full term history](https://github.com/tdwg/dwc/blob/master/vocabulary/term_versions.csv) can be found in the [Darwin Core repository](https://github.com/tdwg/dwc).
{% for class_group in class_groups %}
## {{ class_group.label }}
{% if class_group.label == 'Record-level' %}
This category contains terms that are generic in that they might apply to any type of record in a dataset.
{% endif %}
{% if class_group.label == 'UseWithIRI' %}
For more information on `UseWithIRI`, see [Section 2.5 of the RDF Guide](https://dwc.tdwg.org/rdf/#25-terms-in-the-dwciri-namespace-normative).
{% endif %}
<div class="my-4">
{% for term in class_group.terms %}
<a class="btn btn-sm btn-outline-primary m-1" href="#{{ term.namespace }}:{{ term.label }}">{{ term.label }}</a>
{% endfor %}
</div>
{% if class_group.label != 'Record-level' and class_group.label != 'UseWithIRI' %}
{# Class #}
{% set examples = class_group.examples.split("; ") %}
<table class="table">
<tbody>
<tr class="table-primary"><th colspan="2">{{ class_group.label }} <span class="badge bg-primary float-end">Class</span></th></tr>
<tr><td>Identifier</td><td><a href="{{ class_group.iri }}">{{ class_group.iri }}</a></td></tr>
<tr><td>Definition</td><td>{{ class_group.definition }}</td></tr>
<tr><td>Comments</td><td>{{ class_group.comments }}</td></tr>
<tr><td>Examples</td><td>{% if examples | length == 1 %}{{ examples | first }}{% else %}<ul class="list-group list-group-flush">{% for example in examples %}<li class="list-group-item">{{ example }}</li>{% endfor %}</ul>{% endif %}</td></tr>
</tbody>
</table>
{%endif %}
{% for term in class_group.terms %}
{# Term #}
<p class="invisible">
<span id="{{ term.namespace }}:{{ term.label }}"></span>
{% if term.namespace != "dwciri" %}
<span id="{{ term.label }}"></span>
{% endif %}
</p>
{% set examples = term.examples.split("; ") %}
<table class="table">
<tbody>
<tr class="table-secondary"><th colspan="2">{{ term.label }}</th></tr>
<tr><td>Identifier</td><td><a href="{{ term.iri }}">{{ term.iri }}</a></td></tr>
<tr><td>Definition</td><td>{{ term.definition }}</td></tr>
<tr><td>Comments</td><td>{{ term.comments }}</td></tr>
<tr><td>Examples</td><td>{% if examples | length == 1 %}{{ examples | first }}{% else %}<ul class="list-group list-group-flush">{% for example in examples %}<li class="list-group-item">{{ example }}</li>{% endfor %}</ul>{% endif %}</td></tr>
</tbody>
</table>
{% endfor %}
{% endfor %}
## Cite Darwin Core
To cite Darwin Core in general, use the peer-reviewed article on Darwin Core:
> Wieczorek J, Bloom D, Guralnick R, Blum S, Döring M, et al. (2012) Darwin Core: An Evolving Community-Developed Biodiversity Data Standard. PLoS ONE 7(1): e29715. <https://doi.org/10.1371/journal.pone.0029715>
To cite the standard document upon which this page is built, use the following:
> Darwin Core Maintenance Group. 2021. List of Darwin Core terms. Biodiversity Information Standards (TDWG). <http://rs.tdwg.org/dwc/doc/list/>
To cite this document specifically, use the following:
> Darwin Core Maintenance Group. 2021. Darwin Core Quick Reference Guide. Biodiversity Information Standards (TDWG). <https://dwc.tdwg.org/terms/>