Google 地图边界(将位置数据限制为纬度/经度边界)

发布于 2024-10-05 23:09:54 字数 354 浏览 0 评论 0原文

有人知道如何获取 Google Maps API HTTP 请求/响应以仅返回位于澳大利亚境内的位置吗?

我想我可以添加:

bounds=lat, long | lat Long

根据坐标创建一个方形边界,但谷歌出于某种奇怪的原因不喜欢它。

[NSString stringWithFormat:@"%@%@+Australia&bounds=-9.102097,104.765625|-44.902578,159.697266&sensor=false&region=au", kGoogleGeocodeURL, params];

Anyone know how to get thew Google Maps API HTTP request/response to only return me Locations that fall within Australia ?

I thought I could just add:

bounds=lat, long | lat Long

Creating a square boundary based off Coordinates, but Google for some strange reason isn't liking it.

[NSString stringWithFormat:@"%@%@+Australia&bounds=-9.102097,104.765625|-44.902578,159.697266&sensor=false®ion=au", kGoogleGeocodeURL, params];

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

云雾 2024-10-12 23:09:54

问题解决了,事实证明搜索字符串是正确的,但我需要使用 UTF8Encoding,因为 NSString 不喜欢逗号。

Problem resolved, it turns out that the search string was correct, but I needed to use UTF8Encoding, as NSString didn't like the Commas.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文