Proximity Alert for location coordinates stored in server

人走茶凉 提交于 2019-12-08 01:30:09

问题


I am new to android programming. I want to make an app that can create proximity alerts based on the location coordinates stored in a server, that is compare user's current location with those stored in server and generate an alert if the location is within a particular radius. Is there any way to create proximity alerts for locations stored in a server ? Or is there any better approach for this problem ?

Thanks


回答1:


In android its quite simple to do that.

Please, take a look at this class

http://developer.android.com/reference/android/location/LocationManager.html

especially at this method:

  addProximityAlert(double, double, float, long, android.app.PendingIntent);

this is exactly what you need.

The android SDK docs are really well done. Take always a look there ! :D



来源:https://stackoverflow.com/questions/12669860/proximity-alert-for-location-coordinates-stored-in-server

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!