vector_data library

Data structures for positions, geometries, features and feature collections.

Key features:

  • positions and position arrays based on coordinate arrays
  • simple geometries (point, line string, polygon, multi point, multi line string, multi polygon, geometry collection)
  • features (with id, properties and geometry) and feature collections

This libary exports a subset of package:geobase/geobase.dart.

Usage: import package:geobase/vector_data.dart

Classes

Bounded
A base interface for classes that know their bounding boxes.
BoxCoords
A geospatial bounding box as an iterable collection of coordinate values.
Coordinates
Geospatial coordinate values as an iterable collection of double values.
Feature<T extends Geometry>
A feature is a geospatial entity with id, properties and geometry.
FeatureBuilder<T extends FeatureObject, E extends Geometry>
A builder to create geospatial feature objects of T from FeatureContent.
FeatureCollection<E extends Feature<Geometry>>
A feature collection contains an array of Feature items.
FeatureObject
A common base interface for geospatial feature objects (Feature and FeatureCollection).
Geometry
A base interface for geometry classes.
GeometryBuilder<T extends Geometry, E extends Geometry>
A builder to create geometry objects of T from GeometryContent.
GeometryCollection<E extends Geometry>
A geometry collection with geometries.
LineString
A line string geometry with a chain of positions.
LonLat
A geographic position as an iterable collection of lon and lat values.
LonLatElev
A geographic position as an iterable collection of lon, lat and elev values.
LonLatElevM
A geographic position as an iterable collection of lon, lat, elev and m values.
LonLatM
A geographic position as an iterable collection of lon, lat and m values.
MultiLineString
A multi line string with an array of line strings (each with a chain of positions).
MultiPoint
A multi point geometry with an array of points (each with a position).
MultiPolygon
A multi polygon with an array of polygons (each with an array of rings).
Point
A point geometry with a position.
Polygon
A polygon geometry with one exterior and 0 to N interior rings.
PositionArray
Coordinate values of geospatial positions as an iterable collection.
PositionCoords
A position as an iterable collection of coordinate values.
SimpleGeometry
A base interface for "simple" geometry classes.
XY
A projected position as an iterable collection of x and y values.
XYM
A projected position as an iterable collection of x, y and m values.
XYZ
A projected position as an iterable collection of x, y and z values.
XYZM
A projected position as an iterable collection of x, y, z and m values.

Extensions

BoxCoordinatesExtension
A helper extension on Box to convert data as BoxCoords.
ListCoordinateExtension
A helper extension on List<double> to handle coordinate values.
PositionCoordinatesExtension
A helper extension on Position to convert data as PositionCoords.
PositionIterableCoordinatesExtension
A helper extension on Iterable<Position> to convert data as PositionArray.

Typedefs

AddGeometry<T extends Geometry> = void Function(T geometry, {String? name})
A function to add geometry to some collection with an optional name.