internal static Bind BuildBind(this Geocoding.IGeocoder geocoder, Location location) { try { IEnumerable<Address> addresses = geocoder.ReverseGeocode(location); return Bind.Create(location, addresses); } catch (Exception ex) { return Bind.Create(location.ToString(), ex); } }
internal static Bind BuildBind(Geocoding.IGeocoder geocoder, Location location) { try { IEnumerable <Address> addresses = (geocoder as Geocoding.Google.GoogleGeocoder).ReverseGeocode(location); return(Bind.Create(location, addresses)); } catch (Exception ex) { return(Bind.Create(location.ToString(), ex)); } }
internal static Bind BuildBind(this Geocoding.IGeocoder geocoder, string address) { if (Geocoding.Location.TryParse(address, out Geocoding.Location location)) return BuildBind(geocoder, location); else { try { IEnumerable<Address> addresses = geocoder.Geocode(address); return Bind.Create(address, addresses); } catch (Exception ex) { return Bind.Create(address, ex); } } }
public LinesExcelReader(string excelFile, Geocoding.IGeocoder coder) { this.excelFile = excelFile; this._geocoder = coder; }