Location.fromJson constructor

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

Implementation

Location.fromJson(Map<String, dynamic> json) {
  city = json['city'];
  country = json['country'];
  state = json['state'];
  if (json['coordinates'] != null) {
    coordinates =
        Coordinates.fromJson(json['coordinates'].cast<String, dynamic>());
  }
}