|
@@ -11,9 +11,11 @@ import com.shkpr.service.alambizplugin.constants.GisSurveyCheckStatusEnum;
|
|
|
import com.shkpr.service.alambizplugin.constants.GisSurveyCheckTypeEnum;
|
|
|
import com.shkpr.service.alambizplugin.constants.LogFlagBusiType;
|
|
|
import com.shkpr.service.alambizplugin.dbdao.services.intef.GisSurveyLayerApplyService;
|
|
|
+import com.shkpr.service.alambizplugin.dbdao.services.intef.TypeDefineService;
|
|
|
import com.shkpr.service.alambizplugin.dto.GisSurveyCheckResult;
|
|
|
import com.shkpr.service.alambizplugin.dto.GisSurveyLayerApplyLine;
|
|
|
import com.shkpr.service.alambizplugin.dto.GisSurveyLayerApplyPoint;
|
|
|
+import com.shkpr.service.alambizplugin.dto.TypeDefine;
|
|
|
import org.springframework.scheduling.annotation.Async;
|
|
|
import org.springframework.scheduling.annotation.AsyncResult;
|
|
|
import org.springframework.stereotype.Component;
|
|
@@ -40,15 +42,17 @@ public class GisSurveySystemChecker {
|
|
|
private final String mBizType;
|
|
|
|
|
|
private final GisSurveyLayerApplyService gisSurveyLayerApplyService;
|
|
|
+ private final TypeDefineService typeDefineService;
|
|
|
private final IsolatedPointsFinder isolatedPointsFinder;
|
|
|
private final IsolatedLinesFinder isolatedLinesFinder;
|
|
|
private final DuplicatePointsFinder duplicatePointsFinder;
|
|
|
private final OverlapLinesFinder overlapLinesFinder;
|
|
|
|
|
|
- public GisSurveySystemChecker(GisSurveyLayerApplyService gisSurveyLayerApplyService, IsolatedPointsFinder isolatedPointsFinder, IsolatedLinesFinder isolatedLinesFinder, DuplicatePointsFinder duplicatePointsFinder, OverlapLinesFinder overlapLinesFinder) {
|
|
|
+ public GisSurveySystemChecker(GisSurveyLayerApplyService gisSurveyLayerApplyService, TypeDefineService typeDefineService, IsolatedPointsFinder isolatedPointsFinder, IsolatedLinesFinder isolatedLinesFinder, DuplicatePointsFinder duplicatePointsFinder, OverlapLinesFinder overlapLinesFinder) {
|
|
|
mStrClassName = "GisSurveySystemChecker";
|
|
|
mBizType = LogFlagBusiType.BUSI_GIS_SURVEY.toStrValue();
|
|
|
this.gisSurveyLayerApplyService = gisSurveyLayerApplyService;
|
|
|
+ this.typeDefineService = typeDefineService;
|
|
|
this.isolatedPointsFinder = isolatedPointsFinder;
|
|
|
this.isolatedLinesFinder = isolatedLinesFinder;
|
|
|
this.duplicatePointsFinder = duplicatePointsFinder;
|
|
@@ -103,6 +107,8 @@ public class GisSurveySystemChecker {
|
|
|
points = gisSurveyLayerApplyService.findAddPointByJobId(jobId);
|
|
|
lines = gisSurveyLayerApplyService.findAddLineByJobId(jobId);
|
|
|
}
|
|
|
+ //查询经纬度类型定义
|
|
|
+ List<TypeDefine> typeDefines = typeDefineService.findLatLng();
|
|
|
|
|
|
//孤立点检查
|
|
|
if (points != null && lines != null) {
|
|
@@ -110,7 +116,7 @@ public class GisSurveySystemChecker {
|
|
|
}
|
|
|
//重复点检查
|
|
|
if (points != null) {
|
|
|
- duplicatePointsFuture = duplicatePointsFinder.findDuplicatePoints(points, 6);
|
|
|
+ duplicatePointsFuture = duplicatePointsFinder.findDuplicatePoints(points, typeDefines);
|
|
|
}
|
|
|
//孤立线和重叠线检查
|
|
|
if (lines != null) {
|
|
@@ -146,6 +152,7 @@ public class GisSurveySystemChecker {
|
|
|
|
|
|
//完成检查
|
|
|
result.setCompleteTime(LocalDateTime.now());
|
|
|
+ result.setCheckStatus(GisSurveyCheckStatusEnum.SUCCESS.getCode());
|
|
|
LogPrintMgr.getInstance().printLogMsg(LogLevelFlag.LOG_INFO, mBizType, mStrClassName
|
|
|
, String.format(
|
|
|
"结束执行系统检查;检查类型: %d,项目ID:%s, 任务ID:,%s,用时(毫秒):%d",
|
|
@@ -159,7 +166,7 @@ public class GisSurveySystemChecker {
|
|
|
} catch (InterruptedException | ExecutionException e) {
|
|
|
LogPrintMgr.getInstance().printLogMsg(LogLevelFlag.LOG_ERROR, mBizType, mStrClassName
|
|
|
, String.format(
|
|
|
- "监测到中断或执行异常,开始清除子任务: %d,项目ID:%s, 任务ID:,%s,",
|
|
|
+ "监测到中断或执行异常,开始清除子任务 检查类型:%d,项目ID:%s, 任务ID:,%s,",
|
|
|
checkType,
|
|
|
projId,
|
|
|
jobId
|