Skip to contents
  • Feature objects are different than geometry objects.
    • geometry objects do not have attributes
    • feature objects do have attributes

https://developers.arcgis.com/documentation/common-data-types/feature-object.htm

Features


{
  "geometry": {
    },
  "attributes": {
    }
}
{
  "geometry": {
    "x": -81.49822900952586,
    "y": 36.43139560823739
  },
  "attributes": {
  }
}
{
  "geometry": {
    "x": -81.49822900952586,
    "y": 36.43139560823739
  },
  "attributes": {
    "date": "2023-01-04"
  }
}

Feature Sets

  • featureSet is created from feature objects
    • tables do not return geometry
  • spatial references:
    • should be set at the top level
    • if not set at the top level then it takes the spatial reference of the first feature’s geometry object
      • note that geometry objects don’t have to have spatial reference
    • if neither are set it takes on UnknownCoordinateSystem
      • by default, sf and sfc object should set a top level spatial reference
  • 3 optional fields:
    • objectIdFieldName
    • globalIdFieldName
    • displayFieldName

Spatial References

https://developers.arcgis.com/documentation/common-data-types/geometry-objects.htm

  • can either be a wkid or wkt

  • wkid is the well-known ID e.g. 4326

  • wkt is the well-known text format

  • st_crs() will always return the wkt, that should be used.

  • esriGeometry can also support Vertical Coordinate Systems (VCS) these should be supported, but later

https://developers.arcgis.com/documentation/common-data-types/featureset-object.htm

  • adding a crs uses a lot of text so it should be done only once when possible. so its important to consider when this is done.

Development priority?

  • add features from sf object
    • top level CRS
    • registered as feature set