github.com/PDOK/gokoala@v0.50.6/internal/ogc/tiles/templates/tiles.go.json (about) 1 {{- /*gotype: github.com/PDOK/gokoala/internal/engine.TemplateData*/ -}} 2 { 3 {{ if .Config.OgcAPI.Tiles }} 4 {{$baseUrl := .Config.BaseURL}} 5 "title": "{{ .Config.Title }} - Tiles", 6 "description": "{{ i18n "TilesTextPlain" }}", 7 "links": [ 8 { 9 "rel": "self", 10 "type": "application/json", 11 "title": "Tiles", 12 "href": "{{ $baseUrl }}/tiles?f=json" 13 }, 14 { 15 "rel": "alternate", 16 "type": "text/html", 17 "title": "Tiles as HTML", 18 "href": "{{ .Config.BaseURL }}/tiles?f=html" 19 } 20 ], 21 "tilesets": [ 22 {{range $index, $type := .Config.OgcAPI.Tiles.SupportedSrs}} 23 {{ if (eq $type.Srs "EPSG:28992") }} 24 { 25 "links": [ 26 { 27 "rel": "self", 28 "title": "Access the data as tiles in the tile matrix set 'NetherlandsRDNewQuad'", 29 "href": "{{ $baseUrl }}/tiles/NetherlandsRDNewQuad" 30 }, 31 { 32 "rel": "http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme", 33 "type": "application/json", 34 "title": "Definition of NetherlandsRDNewQuad TileMatrixSet", 35 "href": "{{ $baseUrl }}/tileMatrixSets/NetherlandsRDNewQuad" 36 } 37 ], 38 "dataType": "vector", 39 "crs": "https://www.opengis.net/def/crs/EPSG/0/28992", 40 "tileMatrixSetId": "NetherlandsRDNewQuad", 41 "tileMatrixSetDefinition": "{{ $baseUrl }}/tileMatrixSets/NetherlandsRDNewQuad" 42 } 43 {{end}} 44 {{ if (eq $type.Srs "EPSG:3035") }} 45 {{if $index}},{{end}} 46 { 47 "links": [ 48 { 49 "rel": "self", 50 "title": "Access the data as tiles in the tile matrix set 'EuropeanETRS89_LAEAQuad'", 51 "href": "{{ $baseUrl }}/tiles/EuropeanETRS89_LAEAQuad" 52 }, 53 { 54 "rel": "http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme", 55 "type": "application/json", 56 "title": "Definition of EuropeanETRS89_LAEAQuad TileMatrixSet", 57 "href": "{{ $baseUrl }}/tileMatrixSets/EuropeanETRS89_LAEAQuad" 58 } 59 ], 60 "dataType": "vector", 61 "crs": "https://www.opengis.net/def/crs/EPSG/0/3035", 62 "tileMatrixSetId": "EuropeanETRS89_LAEAQuad", 63 "tileMatrixSetDefinition": "{{ $baseUrl }}/tileMatrixSets/EuropeanETRS89_LAEAQuad" 64 } 65 {{end}} 66 {{ if (eq $type.Srs "EPSG:3857") }} 67 {{if $index}},{{end}} 68 { 69 "links": [ 70 { 71 "rel": "self", 72 "title": "Access the data as tiles in the tile matrix set 'WebMercatorQuad'", 73 "href": "{{ $baseUrl }}/tiles/WebMercatorQuad" 74 }, 75 { 76 "rel": "http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme", 77 "type": "application/json", 78 "title": "Definition of WebMercatorQuad TileMatrixSet", 79 "href": "{{ $baseUrl }}/tileMatrixSets/WebMercatorQuad" 80 } 81 ], 82 "dataType": "vector", 83 "crs": "https://www.opengis.net/def/crs/EPSG/0/3857", 84 "tileMatrixSetId": "WebMercatorQuad", 85 "tileMatrixSetDefinition": "{{ $baseUrl }}/tileMatrixSets/WebMercatorQuad" 86 } 87 {{end}} 88 {{end}} 89 ] 90 {{end}} 91 }