中华联合和监控不在缩小图标
This commit is contained in:
+24
-24
@@ -5,7 +5,7 @@
|
||||
|
||||
|
||||
#import "DDMATrackManager.h"
|
||||
#import <DDLogKit_Private/DDOCLog.h>
|
||||
//#import <DDLogKit_Private/DDOCLog.h>
|
||||
|
||||
@interface DDMATrackManager ()<AMapTrackManagerDelegate>
|
||||
@property (nonatomic, strong)AMapTrackManager *trackManager;
|
||||
@@ -75,14 +75,14 @@
|
||||
//查询到结果,使用 Terminal ID
|
||||
NSString *terminalID = [[[response terminals] firstObject] tid];
|
||||
|
||||
DDLog(@"--------------------------------LBS查询终端成功,terminalID = %@--------------------------------\n--------------------------------准备启动服务--------------------------------",terminalID);
|
||||
// DDLog(@"--------------------------------LBS查询终端成功,terminalID = %@--------------------------------\n--------------------------------准备启动服务--------------------------------",terminalID);
|
||||
|
||||
//启动上报服务(service id),参考下一步
|
||||
self.terminalID = terminalID;
|
||||
[self startService];
|
||||
}
|
||||
else {
|
||||
DDLog(@"--------------------------------LBS查询终端为空--------------------------------\n--------------------------------准备创建终端--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS查询终端为空--------------------------------\n--------------------------------准备创建终端--------------------------------");
|
||||
//查询结果为空,创建新的terminal
|
||||
[self addTerminal:request.terminalName];
|
||||
}
|
||||
@@ -98,7 +98,7 @@
|
||||
|
||||
//创建终端结果
|
||||
- (void)onAddTerminalDone:(AMapTrackAddTerminalRequest *)request response:(AMapTrackAddTerminalResponse *)response {
|
||||
DDLog(@"--------------------------------LBS创建终端成功--------------------------------\n--------------------------------准备开启服务--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS创建终端成功--------------------------------\n--------------------------------准备开启服务--------------------------------");
|
||||
//创建terminal成功
|
||||
NSString *terminalID = [response terminalID];
|
||||
|
||||
@@ -111,32 +111,32 @@
|
||||
- (void)didFailWithError:(NSError *)error associatedRequest:(id)request {
|
||||
if ([request isKindOfClass:[AMapTrackQueryTerminalRequest class]]) {
|
||||
//查询参数错误
|
||||
DDLog(@"--------------------------------LBS查询终端失败--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS查询终端失败--------------------------------");
|
||||
}
|
||||
|
||||
if ([request isKindOfClass:[AMapTrackAddTerminalRequest class]]) {
|
||||
//创建terminal失败
|
||||
DDLog(@"--------------------------------LBS创建终端失败--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS创建终端失败--------------------------------");
|
||||
}
|
||||
|
||||
if ([request isKindOfClass:[AMapTrackAddTrackRequest class]]) {
|
||||
//创建轨迹失败
|
||||
DDLog(@"--------------------------------LBS创建轨迹失败--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS创建轨迹失败--------------------------------");
|
||||
}
|
||||
|
||||
if ([request isKindOfClass:[AMapTrackQueryLastPointRequest class]]) {
|
||||
//查询失败
|
||||
DDLog(@"--------------------------------LBS查询最后位置失败--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS查询最后位置失败--------------------------------");
|
||||
}
|
||||
|
||||
if ([request isKindOfClass:[AMapTrackQueryTrackDistanceRequest class]]) {
|
||||
//查询失败
|
||||
DDLog(@"--------------------------------LBS查询距离失败--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS查询距离失败--------------------------------");
|
||||
}
|
||||
|
||||
if ([request isKindOfClass:[AMapTrackQueryTrackInfoRequest class]]) {
|
||||
//查询轨迹点数据失败
|
||||
DDLog(@"--------------------------------LBS查询历史轨迹点位数据失败--------------------------------");
|
||||
// DDLog(@"--------------------------------LBS查询历史轨迹点位数据失败--------------------------------");
|
||||
}
|
||||
|
||||
if (self.queryFailWithErrorOnDone) {
|
||||
@@ -157,7 +157,7 @@
|
||||
//创建轨迹成功,开始采集
|
||||
self.trackID = response.trackID;
|
||||
|
||||
DDLog(@"---------------------------------创建轨迹成功----------------------------------")
|
||||
// DDLog(@"---------------------------------创建轨迹成功----------------------------------")
|
||||
|
||||
if (self.addTrackOnDone != nil) {
|
||||
self.addTrackOnDone(request, response);
|
||||
@@ -183,8 +183,8 @@
|
||||
- (void)startGatherAndPack{
|
||||
if (self.trackID != nil) {
|
||||
self.trackManager.trackID = self.trackID;
|
||||
NSLog(@"轨迹id---------------%@",self.trackID);
|
||||
DDLog(@"---------------------------------设置轨迹成功----------------------------------")
|
||||
// NSLog(@"轨迹id---------------%@",self.trackID);
|
||||
// DDLog(@"---------------------------------设置轨迹成功----------------------------------")
|
||||
}
|
||||
[self.trackManager startGatherAndPack];
|
||||
}
|
||||
@@ -196,13 +196,13 @@
|
||||
//service 开启结果回调
|
||||
- (void)onStartService:(AMapTrackErrorCode)errorCode {
|
||||
if (errorCode == AMapTrackErrorOK) {
|
||||
DDLog("--------------------------------开启猎鹰服务成功--------------------------------\n--------------------------------准备采集--------------------------------");
|
||||
// DDLog("--------------------------------开启猎鹰服务成功--------------------------------\n--------------------------------准备采集--------------------------------");
|
||||
// 已开启服务成功
|
||||
self.isServing = YES;
|
||||
|
||||
} else {
|
||||
//开始服务失败
|
||||
DDLog("--------------------------------开启猎鹰服务失败--%ld",errorCode);
|
||||
// DDLog("--------------------------------开启猎鹰服务失败--%ld",errorCode);
|
||||
}
|
||||
if (self.startServiceOnDone) {
|
||||
self.startServiceOnDone(errorCode);
|
||||
@@ -215,10 +215,10 @@
|
||||
//关闭猎鹰服务成功
|
||||
self.isServing = false;
|
||||
|
||||
DDLog(@"--------------------------------关闭猎鹰服务成功--------------------------------");
|
||||
// DDLog(@"--------------------------------关闭猎鹰服务成功--------------------------------");
|
||||
} else {
|
||||
//关闭猎鹰服务失败
|
||||
DDLog(@"--------------------------------关闭猎鹰服务失败--------------------------------");
|
||||
// DDLog(@"--------------------------------关闭猎鹰服务失败--------------------------------");
|
||||
}
|
||||
|
||||
if (self.stopServiceOnDone) {
|
||||
@@ -231,10 +231,10 @@
|
||||
if (errorCode == AMapTrackErrorOK) {
|
||||
//开始采集成功
|
||||
self.isGathering = YES;
|
||||
DDLog(@"--------------------------------开始猎鹰采集成功--------------------------------");
|
||||
// DDLog(@"--------------------------------开始猎鹰采集成功--------------------------------");
|
||||
} else {
|
||||
//开始采集失败
|
||||
DDLog(@"--------------------------------开始猎鹰采集失败--------------------------------");
|
||||
// DDLog(@"--------------------------------开始猎鹰采集失败--------------------------------");
|
||||
}
|
||||
|
||||
if (self.startGatherAndPackOnDone) {
|
||||
@@ -247,10 +247,10 @@
|
||||
if (errorCode == AMapTrackErrorOK) {
|
||||
//关闭采集成功
|
||||
self.isGathering = NO;
|
||||
DDLog(@"--------------------------------关闭猎鹰采集成功--------------------------------");
|
||||
// DDLog(@"--------------------------------关闭猎鹰采集成功--------------------------------");
|
||||
} else {
|
||||
//关闭采集失败
|
||||
DDLog(@"--------------------------------关闭猎鹰采集失败--------------------------------");
|
||||
// DDLog(@"--------------------------------关闭猎鹰采集失败--------------------------------");
|
||||
}
|
||||
|
||||
if (self.stopGatherAndPackOnDone) {
|
||||
@@ -287,16 +287,16 @@
|
||||
if (trackID != nil) {
|
||||
request.trackID = self.trackManager.trackID;
|
||||
}
|
||||
DDLog(@"--------------------------------当前猎鹰查询distance:\n起始时间:%lld\n结束时间:%lld--------------------------------",startTime,endTime);
|
||||
// DDLog(@"--------------------------------当前猎鹰查询distance:\n起始时间:%lld\n结束时间:%lld--------------------------------",startTime,endTime);
|
||||
[self.trackManager AMapTrackQueryTrackDistance:request];
|
||||
}
|
||||
|
||||
- (void)onQueryTrackDistanceDone:(AMapTrackQueryTrackDistanceRequest *)request response:(AMapTrackQueryTrackDistanceResponse *)response
|
||||
{
|
||||
//查询成功
|
||||
DDLog(@"--------------------------------onQueryTrackDistanceDone%@--------------------------------", response.formattedDescription);
|
||||
// DDLog(@"--------------------------------onQueryTrackDistanceDone%@--------------------------------", response.formattedDescription);
|
||||
if (self.queryTrackDistanceOnDone != nil) {
|
||||
DDLog(@"--------------------------------当前猎鹰查询distance:%lu--------------------------------",(unsigned long)response.distance);
|
||||
// DDLog(@"--------------------------------当前猎鹰查询distance:%lu--------------------------------",(unsigned long)response.distance);
|
||||
self.queryTrackDistanceOnDone(request, response);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user