toMap method

Map<String, double> toMap()

Converts this GeoPoint to a map.

Example:

final point = GeoPoint(latitude: 37.7749, longitude: -122.4194);
final map = point.toMap();
print(map); // {latitude: 37.7749, longitude: -122.4194}

Implementation

Map<String, double> toMap() {
  return {
    'latitude': latitude,
    'longitude': longitude,
  };
}