Making a Location object in Android with latitude and longitude values

后端 未结 3 1062
南笙
南笙 2020-12-07 16:12

I have a program in which latitude and longitude values of a location are stored in a database, which I download.

I want to get the distance between these coordinat

3条回答
  •  悲&欢浪女
    2020-12-07 16:52

    You may create locations using their constructor, then set the latutude and longitude values.

    final Location location = new Location("yourprovidername");
    location.setLatitude(1.2345d);
    location.setLongitude(1.2345d);
    

提交回复
热议问题