keyByPolylineId function
Implementation
Map<String, Polyline> keyByPolylineId(Iterable<Polyline> polylines) {
// ignore: unnecessary_null_comparison
if (polylines == null) {
return <String, Polyline>{};
}
return Map<String, Polyline>.fromEntries(polylines.map((Polyline polyline) =>
MapEntry<String, Polyline>(polyline.id, polyline.clone())));
}