Polyline constructor

Polyline({
  1. int? id,
  2. required List<LatLng> points,
  3. Color? color,
  4. double? width,
  5. double? alpha,
})

Each polyline must have at least two points.

Implementation

Polyline({
  this.id,
  required this.points,
  this.color,
  this.width,
  this.alpha,
}) : assert(points.length >= 2, 'Polyline must have at least two points');