Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
serde_esri
Esri JSON parsing library.
This crate provides representations of Esri JSON objects with serde::Deserialize and serde::Serialize trait implementations.
serde_esri has additional features:
geoimplementsFromfor the Esri JSON objects.geoarrowprovides compatibility with arrow and geoarrow by implementing geoarrow geometry traits as well as providing a utility functionfeatureset_to_geoarrow()which converts aFeatureSetto an arrowGeoTable.places-clientprovides an API client for the Places Service REST API.
Example usage:
This example reads a few features from a feature service and returns a FeatureSet struct. It illustrates the use of the geo and geoarrow features.
[]
= "0.28.0"
= "0.2.0"
= { = "0.12.3", = ["blocking"] }
= { = "0.2.0", = ["geo", "geoarrow"] }
= "1.0.115"
use ;
use featureset_to_geoarrow;
use FeatureSet;
use Read;
Supported Esri JSON objects:
Geometry
Esri Geometries Objects are encoded by the following structs:
EsriPointEsriMultiPoint<N>EsriPolyline<N>EsriPolygon<N>EsriEnvelope
They are encapsulated by the EsriGeometry enum:
The parameter N is used to specify the dimension of the geometries. Use <2> for 2 dimensional data, <3> for Z values and <4> when M and Z are present.
FeatureSets
An Esri JSON FeatureSet is what is most commonly returned from a Feature Service. It is comprised of a number of optional fields and most importantly, a vector of Features.
Features are a struct with a geometry and an attributes field. The geometry must be one of the possible geometry types and attributes can be an key-value pair.
FeatureSets are defined as
Spatial References
Esri Spatial Reference Objects are represented by the SpatialReference struct. Note that while all fields are optional, one should always be provided.
Places Service API Client
Activate the PlaceAPI client in your Cargo.toml
[]
= { = "0.3.0", = ["places-client"] }