0
在我的應用程序中,我需要從當前位置查找附近的地方,並將這些地點的ID導出到我的數據庫。就這些。我將下面的代碼用於Google Places API,然後從地圖上的當前位置看到標記的附近地點。然後我想獲得這些地方的ID。我怎樣才能得到這個?iOS - 附近有Google Places API導出到數據庫的附近地點
- (IBAction)pickPlace:(UIButton *)sender {
CLLocationCoordinate2D center = CLLocationCoordinate2DMake(51.5108396, -0.0922251);
CLLocationCoordinate2D northEast = CLLocationCoordinate2DMake(center.latitude + 0.001, center.longitude + 0.001);
CLLocationCoordinate2D southWest = CLLocationCoordinate2DMake(center.latitude - 0.001, center.longitude - 0.001);
GMSCoordinateBounds *viewport = [[GMSCoordinateBounds alloc] initWithCoordinate:northEast coordinate:southWest];}