如何通过意图导航多个航点到Android的标准谷歌地图应用程序? [英] How to pass multiple waypoint to standard google map app in android through intent for navigation ?

查看:180
本文介绍了如何通过意图导航多个航点到Android的标准谷歌地图应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经做了一些调查,发现通过Google地图网站添加多个目的地是可能的,并且可以将整个导航计划发送到谷歌地图Android应用程序,使其完美。

但在我的情况下,我想通过我的应用程序动态生成多个目标导航网址,并通过意图在手机中打开Goog​​le地图应用程序传递它。
如何实现任何想法都是有用的。

= https://developers.google.com/maps/documentation/directions/intro#DirectionsRequests> ' https://maps.googleapis.com/maps/api/directions/json?' 。但是,您最多限制8个航点。要获取更多航点,您需要获取 Google Maps API for Work ,这将允许您达到23个航点。

关于Google Maps Intents,为了以意图启动地图,您必须首先创建一个指定其动作,URI和包的Intent对象。有关详情,请查看此链接: https://developers.google.com/maps/documentation/android- api /意图


I have done some research and i found that adding multiple destination is possible through google map website and one can send the entire navigation plan to google map android app it works perfect.

But in my case i want to generate multiple destination navigation url dynamically through my app and pass it via intent to open google map app in phone. How can this be achieved any ideas would be helpfull .

解决方案

You may generate multiple destination by requesting 'https://maps.googleapis.com/maps/api/directions/json?'. However, you are limited up to 8 waypoints. To get more waypoints for a request, you'll need to get Google Maps API for Work which will allow you up to 23 waypoints.

Regarding Google Maps Intents, in order to launch Maps with an intent, you must first create an Intent object specifying its action, URI and package. For more details, check this link: https://developers.google.com/maps/documentation/android-api/intents

这篇关于如何通过意图导航多个航点到Android的标准谷歌地图应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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