在swift中将纬度和经度转换为PFGeoPoint

时间:2015-09-02 10:03:17

标签: swift parse-platform geolocation

在objective-c中,我们可以使用geoPointWithLatitude将纬度和经度转换为PFGeoPoint。 但我无法在swift中找到任何方法。

提前致谢。

1 个答案:

答案 0 :(得分:1)

使用此代码。可能会帮助你。

var descLocation: PFGeoPoint = PFGeoPoint()

descLocation.latitude = coord.latitude
descLocation.longitude = coord.longitude