Map<String, Marker> keyByMarkerId(Iterable<Marker> markers) { return Map<String, Marker>.fromEntries(markers.map( (Marker marker) => MapEntry<String, Marker>(marker.id, marker.clone()))); }