有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!


共 (1) 个答案

  1. # 1 楼答案

    我认为您可以参考Location API来计算当前位置和另一个位置之间的距离

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

    我认为你可以选择以下方法之一:

    public static void distanceBetween (double startLatitude, double startLongitude, double endLatitude, double endLongitude, float[] results)
    
    public float distanceTo (Location dest)