Features - GeoJSON

specstableimplmature

Encode features as GeoJSON.

Scope

Conformance Classes

Features GeoJSON implements all requirements of conformance class GeoJSON from OGC API - Features - Part 1: Core 1.0open in new window for the two mentioned resources.

Configuration

Options

NameDefaultDescriptionTypeSince
buildingBlock
Always GEO_JSON.
string
v2.0
transformations
{}
Property transformations do not affect data sources, they are applied on-the-fly as part of the encoding. Filter expressions do not take transformations into account, they have to be based on the source values. That means queryable properties (see queryables in Features) should not use transformations in most cases. The exception to the rule is the HTML encoding, where readability might be more important than filter support.
object
v2.0
enabled
true
Enable the building block?
boolean
v2.0
defaultProfiles
{"rel": "rel-as-link", "geojson": "rfc7946"}
Change the default value of the profile parameter for this feature format. The value is an object where the key is the id of a profile set, such as rel, and the value is the default profile for the profile set, e.g., rel-as-key. These defaults override the defaults specified in the Features building block.
object
v4.2

Examples

An example of flattening. The non-flattened feature


{
  "type" : "Feature",
  "id" : "1",
  "geometry" : {
    "type" : "Point",
    "coordinates" : [ 7.0, 50.0 ]
  },
  "properties" : {
    "name" : "Beispiel",
    "inspireId" : "https://example.org/id/soziales/kindergarten/1",
    "serviceType" : {
      "title" : "Kinderbetreuung",
      "href" : "https://inspire.ec.europa.eu/codelist/ServiceTypeValue/childCareService"
    },
    "pointOfContact" : {
      "address" : {
        "thoroughfare" : "Beispielstr.",
        "locatorDesignator" : "123",
        "postCode" : "99999",
        "adminUnit" : "Irgendwo"
      },
      "telephoneVoice" : "0211 16021740"
    },
    "occupancy" : [ {
      "typeOfOccupant" : "vorschule",
      "numberOfOccupants" : 20
    }, {
      "typeOfOccupant" : "schulkinder",
      "numberOfOccupants" : 25
    } ]
  }
}

looks like this flattened with the default separator:


{
  "type" : "Feature",
  "id" : "1",
  "geometry" : {
    "type" : "Point",
    "coordinates" : [ 7.0, 50.0 ]
  },
  "properties" : {
    "name" : "Beispiel",
    "inspireId" : "https://example.org/id/soziales/kindergarten/1",
    "serviceType.title" : "Kinderbetreuung",
    "serviceType.href" : "https://inspire.ec.europa.eu/codelist/ServiceTypeValue/childCareService",
    "pointOfContact.address.thoroughfare" : "Otto-Pankok-Str.",
    "pointOfContact.address.locatorDesignator" : "29",
    "pointOfContact.address.postCode" : "40231",
    "pointOfContact.address.adminUnit" : "Düsseldorf",
    "pointOfContact.telephoneVoice" : "0211 16021740",
    "occupancy.1.typeOfOccupant" : "vorschule",
    "occupancy.1.numberOfOccupants" : 20,
    "occupancy.2.typeOfOccupant" : "schulkinder",
    "occupancy.2.numberOfOccupants" : 25
  }
}

The relevant options in the configuration file:


- buildingBlock: GEO_JSON
  transformations:
    '*':
      flatten: '.'