高德地图开发iOS 猎鹰SDK轨迹查询—查询终端实时位置

高德地图开发iOS 猎鹰SDK轨迹查询—查询终端实时位置

查询终端实时位置 最后更新时间: 2021年01月22日

可以使用服务id和终端id查询某个终端最后一次上报的位置信息,查询代码如下:

Objective-C

    AMapTrackQueryLastPointRequest *request = [[AMapTrackQueryLastPointRequest alloc] init];
    request.serviceID = self.trackManager.serviceID;
    request.terminalID = self.trackManager.terminalID;
    [self.trackManager AMapTrackQueryLastPoint:request];

    - (void)onQueryLastPointDone:(AMapTrackQueryLastPointRequest *)request response:(AMapTrackQueryLastPointResponse *)response
    {
        //查询成功
        NSLog(@"onQueryLastPointDone%@", response.formattedDescription);
    }

    - (void)didFailWithError:(NSError *)error associatedRequest:(id)request {
        if ([request isKindOfClass:[AMapTrackQueryLastPointRequest class]]) {
            //查询失败
        }
    }

🚀 如未找到文章请搜索栏搜素 | Ctrl+D收藏本站 | 联系邮箱:15810050733@qq.com