toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final Map<String, dynamic> data = new Map<String, dynamic>();
  data['description'] = this.description;
  data['id'] = this.id;
  if (this.matchedSubstrings != null) {
    data['matched_substrings'] =
        this.matchedSubstrings!.map((v) => v.toJson()).toList();
  }
  data['place_id'] = this.placeId;
  data['reference'] = this.reference;
  if (this.structuredFormatting != null) {
    data['structured_formatting'] = this.structuredFormatting!.toJson();
  }
  if (this.terms != null) {
    data['terms'] = this.terms!.map((v) => v.toJson()).toList();
  }
  data['types'] = this.types;
  data['lat'] = this.lat;
  data['lng'] = this.lng;

  return data;
}