getAsGeoPoint method
Get the geo point corresponding to key
in the map.
If key
is not found, the geo point of orElse
is returned.
Implementation
GeoPoint getAsGeoPoint(K key, [GeoPoint? orElse]) {
assert(key != null, "The key is empty.");
if (!containsKey(key)) {
return orElse ?? const GeoPoint(0, 0);
}
return (this[key] as GeoPoint?) ?? orElse ?? const GeoPoint(0, 0);
}