/// <summary> /// Creates request to translate given address to its geographical location. /// </summary> /// <param name="address">Address value.</param> public async void CreateGeocodeRequestMethod(string address) { try { var request = _mapService.CreateGeocodeRequest(address); _latestGeocodeResponse = await request.GetResponseAsync(); GeocodeRequestSuccess?.Invoke(this, new EventArgs()); } catch (Exception e) { if (e.Message.Contains(NETWORK_UNREACHABLE_ERROR) || e.Message.Contains(INVALID_OPERATION_ERROR)) { GeocodeRequestConnectionFailed?.Invoke(this, new EventArgs()); } if (e.Message.Contains(NOT_FOUND_ERROR)) { GeocodeRequestNotFound?.Invoke(this, new EventArgs()); } } }