--- layout: default --- {{ content }} {% assign profile_file = "geolocator-dp-profile" %} {% assign properties1 = site.data[profile_file].allOf[1].properties %} {% assign required1 = site.data[profile_file].allOf[1].required %}

Datapackage

Source: {{ profile_file }}.json

{% for p1_raw in properties1 %} {% assign p1_name = p1_raw[0] %} {% assign p1 = p1_raw[1] %} {% assign p1_id = p1_name %}

{{ p1_name }}{% if required1 contains p1_name %}*{% endif %}{% if p1['computed'] %}{% if required1 contains p1_name %},{% endif %}+{% endif %}

{{ p1.description | markdownify }} {% if p1['skos:exactMatch'] %}

Same as {% for term in p1['skos:exactMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %}

{% elsif p1['skos:narrowMatch'] %}

Broader than {% for term in p1['skos:narrowMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %}

{% elsif p1['skos:broadMatch'] %}

Narrower than {% for term in p1['skos:broadMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %}

{% elsif p1['skos:relatedMatch'] %} Related to {% for term in p1['skos:relatedMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% elsif p1['skos:closeMatch'] %} Close to {% for term in p1['skos:closeMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% endif %} {% if p1.properties %} {% assign properties2 = p1.properties %} {% assign required2 = p1.required %} {% elsif p1.items.properties %} {% assign properties2 = p1.items.properties %} {% assign required2 = p1.items.required %} {% elsif p1.items.oneOf[0].properties %} {% assign properties2 = p1.items.oneOf[0].properties %} {% assign required2 = p1.items.oneOf[0].required %} {% else %} {% assign properties2 = false %} {% endif %} {% if properties2 %} {% for p2_raw in properties2 %} {% assign p2_name = p2_raw[0] %} {% assign p2 = p2_raw[1] %} {% assign p2_id = p2_name %} {% endfor %}
Name Definition Type
{{ p2_name }} {% if required2 contains p2_name %}*{% endif %} {{ p2.description | markdownify }} {% if p2.const or p2.enum or p2.items.enum %} Constraints
    {% if p2.const %}
  • const: {{ p2.const }}
  • {% endif %} {% if p2.enum %}
  • enum: {{ p2.enum | join: ", " }}
  • {% endif %} {% if p2.items.enum %}
  • enum: {{ p2.items.enum | join: ", " }}
  • {% endif %}
{% endif %} {% if p2.example and p2.example != "" %}

Example: {{ p2.example }}

{% endif %} {% if p2['skos:exactMatch'] %} Same as {% for term in p2['skos:exactMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% elsif p2['skos:narrowMatch'] %} Broader than {% for term in p2['skos:narrowMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% elsif p2['skos:broadMatch'] %} Narrower than {% for term in p2['skos:broadMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% elsif p2['skos:relatedMatch'] %} Related to {% for term in p2['skos:relatedMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% elsif p2['skos:closeMatch'] %} Close to {% for term in p2['skos:closeMatch'] %}{{ term }}{% unless forloop.last %}, {% endunless %}{% endfor %} {% endif %}
{{ p2.type }}
{% endif %} {% if p1.examples and p1.examples != "" %}

Example:

{% capture json_string %} {{ p1.examples }} {% endcapture %} {% highlight json %}{{ json_string | strip }} {% endhighlight %} {% endif %}{% endfor %}