爪哇 - 谷歌地图API - 两个地址之间的距离 [英] Java - Google maps API - distance between two addresses

查看:256
本文介绍了爪哇 - 谷歌地图API - 两个地址之间的距离的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用谷歌地图API如何确定两个地点之间的行驶距离?平台-Java

Using Google Maps API how to determine the driving distance between two locations ? Platform -Java

推荐答案

您将需要使用的谷歌地图的Web服务。你可以让一个HTTP请求,并指定你的两个位置作为参数,并取回JSON(或XML),说明这两个点之间的路线。

You will need to use the Google Directions Web Service. You can make an HTTP request, specifying your two locations as parameters, and get back JSON (or XML) describing the directions between the two points.

NB 借助谷歌地图服务条款明确规定,使用谷歌地图的Web服务,而无需把结果在谷歌地图是禁止的。

N.B. The Google Maps terms of service explicitly states that using the Google Maps Web Services without putting the results on a Google Map is prohibited.

这篇关于爪哇 - 谷歌地图API - 两个地址之间的距离的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆