Nedan ser vi ett nästan komplett exempel uttryckt i formatet GeoJSON.
{
"type": "FeatureCollection",
"features": [
{
"type": "Trail",
"properties": {
"category": "http://data.visitsweden.com/terms/Hiking",
"name": "Example Trail",
"description": "This is an example trail for demonstration purposes.",
"fromLocation": "Example Start Location",
"toLocation": "Example End Location",
"lighting": true,
"length": 10.5,
"ascentInMeters": 500,
"unitCode": "KMT",
"highestPoint": 1500,
"lowestPoint": 1000,
"resource": "http://example.com/gpx/example_trail.gpx",
"image": ["http://example.com/images/trail1.jpg", "http://example.com/images/trail2.jpg"],
"stages": [
{
"order": 1,
"place": "Stage 1 Location",
"length": 5.3,
"unitCode": "KMT",
"elevation": {
"maxValue": 1300,
"minValue": 1100
},
"resource": "http://example.com/gpx/stage1.gpx"
},
{
"order": 2,
"place": "Stage 2 Location",
"length": 5.2,
"unitCode": "KMT",
"elevation": {
"maxValue": 1500,
"minValue": 1200
},
"resource": "http://example.com/gpx/stage2.gpx"
}
],
"gradingScale": "T2",
"geographicResource": "http://example.com/geoshape/example_geoshape.gml"
},
"geometry": {
"type": "LineString",
"coordinates": [
[10.0, 50.0],
[10.5, 50.5],
[11.0, 51.0]
]
}
}
]
}
Nedan ser vi ett nästan komplett exempel uttryckt i formatet GeoJSON-LD.
{
"@context": {
"geojson": "https://purl.org/geojson/vocab#",
"schema": "http://schema.org/",
"odta": "https://odta.io/voc/",
"Feature": "geojson:Feature",
"FeatureCollection": "geojson:FeatureCollection",
"LineString": "geojson:LineString",
"Point": "geojson:Point",
"geometry": "geojson:geometry",
"coordinates": "geojson:coordinates",
"properties": "geojson:properties"
},
"type": "FeatureCollection",
"features": [
{
"@type": ["Feature", "odta:Trail"],
"type": "Feature",
"properties": {
"@id": "http://example.com/trails/example-trail",
"schema:category": "http://data.visitsweden.com/terms/Hiking",
"schema:name": "Example Trail",
"schema:description": "This is an example trail for demonstration purposes.",
"schema:fromLocation": "Example Start Location",
"schema:toLocation": "Example End Location",
"schema:lighting": true,
"schema:length": 10.5,
"schema:distance": 10.5,
"schema:value": 500,
"schema:unitCode": "KMT",
"schema:maxValue": 1500,
"schema:minValue": 1000,
"schema:geoContains": "http://example.com/gpx/example_trail.gpx",
"schema:image": [
"http://example.com/images/trail1.jpg",
"http://example.com/images/trail2.jpg"
],
"schema:itinerary": {
"@type": "schema:ItemList",
"schema:itemListElement": [
{
"@type": "schema:ListItem",
"schema:item": {
"@id": "http://example.com/stage1",
"schema:name": "Stage 1 Location",
"schema:length": 5.3,
"schema:unitCode": "KMT",
"schema:elevation": {
"@type": "schema:QuantitativeValue",
"schema:maxValue": 1300,
"schema:minValue": 1100
},
"schema:geoContains": "http://example.com/gpx/stage1.gpx",
"geometry": {
"type": "Point",
"coordinates": [10.0, 50.0]
}
}
},
{
"@type": "schema:ListItem",
"schema:item": {
"@id": "http://example.com/stage2",
"schema:name": "Stage 2 Location",
"schema:length": 5.2,
"schema:unitCode": "KMT",
"schema:elevation": {
"@type": "schema:QuantitativeValue",
"schema:maxValue": 1500,
"schema:minValue": 1200
},
"schema:geoContains": "http://example.com/gpx/stage2.gpx",
"geometry": {
"type": "Point",
"coordinates": [11.0, 51.0]
}
}
}
]
}
},
"geometry": {
"type": "LineString",
"coordinates": [
[10.0, 50.0],
[10.5, 50.5],
[11.0, 51.0]
]
}
}
]
}
Nedan ser vi ett nästan komplett RDF exempel uttryckt i formatet Turtle.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix visit: <http://data.visitsweden.com/terms/> .
@prefix schema: <http://schema.org/> .
@prefix geojson: <https://purl.org/geojson/vocab#> .
@prefix odta: <https://odta.io/voc/> .
<http://example.com/trails/example-trail> a odta:Trail ;
schema:category "visit:Hiking" ;
schema:name "Example Trail" ;
schema:description "This is an example trail for demonstration purposes." ;
schema:fromLocation "Example Start Location" ;
schema:toLocation "Example End Location" ;
schema:lighting true ;
schema:length 10.5 ;
schema:distance 10.5 ;
schema:value 500 ;
schema:unitCode "KMT" ;
schema:maxValue 1500 ;
schema:minValue 1000 ;
schema:geoContains <http://example.com/gpx/example_trail.gpx> ;
schema:image <http://example.com/images/trail1.jpg>,
<http://example.com/images/trail2.jpg> ;
schema:itinerary [
a schema:ItemList ;
schema:itemListElement [
a schema:ListItem ;
schema:item <http://example.com/stage1>
],
[
a schema:ListItem ;
schema:item <http://example.com/stage2>
]
] ;
visit:grade "T2" ;
visit:geographicResource <http://example.com/geoshape/example_geoshape.gml> ;
geojson:geometry [
a geojson:LineString ;
geojson:coordinates "[10.0, 50.0] [10.5, 50.5] [11.0, 51.0]"
] .
<http://example.com/stage1> a geojson:Feature ;
schema:name "Stage 1 Location" ;
schema:length 5.3 ;
schema:unitCode "KMT" ;
schema:elevation [
a schema:QuantitativeValue ;
schema:maxValue 1300 ;
schema:minValue 1100
] ;
schema:geoContains <http://example.com/gpx/stage1.gpx> ;
geojson:geometry [
a geojson:Point ;
geojson:coordinates "[10.0, 50.0]"
] .
<http://example.com/stage2> a geojson:Feature ;
schema:name "Stage 2 Location" ;
schema:length 5.2 ;
schema:unitCode "KMT" ;
schema:elevation [
a schema:QuantitativeValue ;
schema:maxValue 1500 ;
schema:minValue 1200
] ;
schema:geoContains <http://example.com/gpx/stage2.gpx> ;
geojson:geometry [
a geojson:Point ;
geojson:coordinates "[11.0, 51.0]"
] .