opengeospatial / 2D-Tile-Matrix-Set

OGC 2D Tile Matrix Set & TileSet Metadata standard
https://www.ogc.org/standards/tms
Apache License 2.0
8 stars 10 forks source link

How to JSON encode geometry and properties in the layer description in TileSet metadata #16

Closed joanma747 closed 3 years ago

joanma747 commented 3 years ago

In JSON encodings proposed by Jerome

  1. We should probably have an enumeration type for geometry type, suggesting:
  • points
  • lines
  • polygons
  1. For the layer properties, as previously discussed we should coordinate this with the general question of queryables / presentables / schema, and perhaps additional things specified in that layer metadata could also be things specified by OGC API - Common Part 2 either at the extended /collections/{collectionId} end-point, or at a sub-end-point like /collections/{collectionId}/{something}.

Our current implementation of queryables uses "id" rather than "name",

In my opinion it should be better to have a "schemas" : { } (exactly as OpenAPI)

The content of "schemas" is under discussion. One alternative could be to have a a full GeoJSON schema personalized to the feature types. These mean, defining a geometry and a property sections and setting the geometry to a single geomentry (e.g. LineString) and the properties to the actual property names and types.

joanma747 commented 3 years ago

This is what we agreed to use.

"propertiesSchema" :
      {
         "type": "object",
         "properties" :
         {
            "F_CODE" :
            {
               "title" : "Feature Code",
               "type" : "string",
               "enum" : [ "EA010", "EA040", "AM020" ]
            },
            "FFN" : { "type" : "integer" },
            "FCSUBTYPE" :
            {
               "title" : "Feature subtype",
               "type" : "integer",
               "enum" : [ 100380, 100384 ]
            },
            "ZI005_FNA" : { "type" : "string"  }
         }
    }
joanma747 commented 3 years ago

Solution has been applied to the JSON schemas using the meta-schema for JSON and in section 9 (JSON encoding) there is a table mapping the UML class with the JSON schema tags.. Since this was presented yesterday (2021-02-11) and there was no objection, I'm closing the issue