LineString constructor

LineString(
  1. Iterable<LatLng> nodes
)

Implementation

LineString(Iterable<LatLng> nodes) : nodes = List.of(nodes, growable: false) {
  if (this.nodes.length < 2)
    throw GeometryException('A path must have at least two nodes.');
}