XML Schema, Schematron, JSON Schema, JSON-LD validation

Copyright © 2015 Open Geospatial Consortium. 15 and links Links between objects xlink not yet clear with type:id Unknown properties yes no 2 yes Unknown objects yes no 2 yes Namespaces yes yes no yes by definition all keys are full URIs Conditional rules no yes no no Connection to RDF no no no yes 1 Could be provided by the vocabulary pointed by the URIs 2 JSON is considered more flexible and extensible so an unknown property is considered an extension and it is ignored. 3 use “type”:”array”, minItems : min, maxItems: max: http:stackoverflow.comquestions23141511how-to-map-uml-composition- cardinality-to-json-schema 4 limited to the JSON data types: “string”, “number”, “object”, “array”... The authors of this ER believe that JSON-LD could be used as a validation strategy with the adoption of some additional conventions. In fact, many examples in this document have been validated using the JSON-LD playground. It is out of scope of this ER to try to completely assess this possibility but the authors recommend doing additional testing in the future. Recommendation 4: Consider the combined use of JSON schema and the context section of a JSON-LD file possibly in combination with the ontologies linked to it as a means for validating a JSON file in the OGC. The next OGC Testbed could include a test on this approach as an activity. Target: Testbed-12 Recommendation 5: Consider the possibilities of using the namespace URIs in context section of a JSON-LD file as a means to connect to formal ontologies structured in OWL SKOS or other RDF encoding as a way to validate complex types in JSON files in the OGC. The next OGC Testbed could include a test on this approach as an activity. Target: Testbed-12 NOTE: https:developers.google.comstructured-datatesting-tool that will be mentioned later already verifies complex data structures in files written in JSON-LD and a similar approach is suggested here. 16 Copyright © 2015 Open Geospatial Consortium.

5.5 GeoJSON

In 2008, a group of individuals including some OGC members formed a community project to define and published a JSON encoding for simple geometries and features. The result of this work is GeoJSON. GeoJSON is a format for encoding simple feature geographic data structures. A GeoJSON object may represent a geometry, a feature, or a collection of features. GeoJSON supports the following geometric types: Point, LineString, Polygon, MultiPoint, MultiLineString, MultiPolygon, and GeometryCollection. Features in GeoJSON contain a geometry object and additional properties, and features are grouped in a feature collection. Version 1 also refereed as the 2008 version was released in 16 June 2008 and can be found in geojson.org. Later, 2014 the group submitted a draft into the IETF process. At the moment they have been very active releasing 4 draft versions, the last one in February 2015. This is how the river example, looks like encoded in GeoJSON: { type: Feature, geometry: { type: LineString, coordinates: [ [-95.2075, 47.239722], [-89.253333, 29.151111] ] }, properties: { url: http:en.wikipedia.orgwikiMississippi_River, name: mississipi, length: 3734, discharge: 16790, source: Lake Itasca, mouth: Gulf of Mexico, country: United States of America, bridges: [Eads Bridge, Chain of Rocks Bridge] } } As you can see, an object Feature has 3 members “type” “geometry” and “properties”. GeoJSON mainly sets restrictions on the values of type and in the content of the geometry element that mainly contains an n dimensional array of coordinates see the red parts above. GeoJSON does not impose any restriction on the members of the properties, so they can be numbers, texts or other objects only limited by the JSON types themselves. As stated in OGC 14-113 OGC JSON Position Statement, GeoJSON is getting momentum and “OGC members and the broader geo-community are using or intending on using JSON encodings for some or all of their applications that require geographic data encoding and transfer”. Many people are starting to distribute maps in the internet in Copyright © 2015 Open Geospatial Consortium. 17 this format e.g.: https:github.comjohanworld.geo.json and applications to download e.g.: http:geojson-maps.kyd.com.au and editing online e.g.: http:geojson.io are proliferating. In particular, GitHub offers the possibility to upload GeoJSON files with