Expand description
Scalar references onto a parent GeoArrow array.
For all “native” GeoArrow scalar types, (all types defined in this module) it is O(1)
and
allocation-free for any coordinate access.
For “serialized” scalars emitted from the GenericWkbArray
,
WkbViewArray
,
GenericWktArray
, and
WktViewArray
, there is an initial parsing step when accessing
the scalar from the GeoArrowArrayAccessor
trait.
All scalars implement geo_traits
. You can iterate through geometry parts directly using the
APIs exposed by geo_traits
. Or, for simplicity at the cost of a memory copy, you can use
the traits defined in geo_traits::to_geo
to convert these scalars to [geo_types
] objects
(though keep in mind ).
§Converting to [geo_types
]
You can convert these scalars to [geo_types
] objects using the geo_traits::to_geo
traits.
There are a couple drawbacks:
geo_types
only supports 2D geometries. Any other dimensions will be dropped.geo_types
doesn’t support empty points. This is why bothToGeoGeometry::to_geometry
andToGeoGeometry::try_to_geometry
exist. The former will panic on any empty points.
Structs§
- Geometry
Collection - An Arrow equivalent of a GeometryCollection
- Interleaved
Coord - An Arrow equivalent of a Coord
- Line
String - An Arrow equivalent of a LineString
- Multi
Line String - An Arrow equivalent of a MultiLineString
- Multi
Point - An Arrow equivalent of a MultiPoint
- Multi
Polygon - An Arrow equivalent of a MultiPolygon
- Point
- An Arrow equivalent of a Point
- Polygon
- An Arrow equivalent of a Polygon
- Rect
- An Arrow equivalent of a Rect
- Separated
Coord - An Arrow equivalent of a Coord