Android的 - 从一个应用程序启动谷歌导航应用程序、Android

2023-09-05 05:36:49 作者:别等时光非礼了梦想

我目前在Android应用程序,该用户需要一些坐标进步(从开始由用户定义的GPS和归宿点)

I am currently in progress of an android app, which takes some coordinates by the user (Starting point from gps and destination defined by the user)

我想我的应用程序启动谷歌导航,以便它可以通过这些点指导用户。在下一个步骤,我想给导航多个点(例如,一些兴趣点),使其通过一个包含所有点的具体路线引导用户。

I would like my app to launch the google navigation so that it can guide the user through these points. At a next step, I would like to give navigation more points (eg some points of interest) so that it will guide the user through a specific route containing all the points.

这可能吗?所有这一切,我觉得是没有记录的做法,并没有例子。是否有任何人谁解决了这个问题?如果没有,可以有人建议一些其他的导航PROGRAMM?

Is that possible? All that I find is no-documented practices and no examples. Is there anyone who has solved this problem? If not, can someone suggest some other navigation programm?

感谢你在前进, 乔治

推荐答案

您当然可以引导他们到一个点:

You can certainly guide them to a single point:

Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("google.navigation:q=" +mLat+","+mLong));
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(intent);

不知道如何设置航点可能是一些方法来做到这一点,我认为API是未公开的,以便使用您自己的风险。你可以有你的应用程序在后台听GPS信息,并把它提示用户在某些点上。

Not sure about setting way points might be some way to do it, I think the API is undocumented so use at your own risk. You could have your app in the background listening to the GPS information and have it prompt the user at certain points.

 
精彩推荐
图片推荐