MultiPolygon.fromJson constructor

MultiPolygon.fromJson(
  1. Map<String, dynamic> json
)

Creates a MultiPolygon from JSON data.

Implementation

factory MultiPolygon.fromJson(Map<String, dynamic> json) {
  final coordinates = json['coordinates'];

  return MultiPolygon(
    _toLatLngListListList(coordinates).map((e) => Polygon(e)).toList(),
  );
}