PolylineSimplifier class abstract

PolylineSimplifier helps to reduce the number of points in the polyline by removing redundant elements using Douglas–Peucker algorithm, so that result stays within PolylineSimplifierOptions.

Typical use case is to perform input preparation step before invoking computationally heavy API. Such API have an upper limit on the input collection size and is subject to reduced performance when collection is huge. Examples of such API are:

  • TrafficEngine methods which accept a GeoCorridor;
  • RoutePrefetcher.prefetchGeoCorridor.

Constructors

PolylineSimplifier()
Creates a new instance of PolylineSimplifier.
factory

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
simplify(List<GeoCoordinates> polyline, PolylineSimplifierOptions simplificationParameters, PolylineSimplificationCallback callback) TaskHandle
Reduces the number of points in the input polyline.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited