【修复线网数据发布出错】

This commit is contained in:
weizhihong 2023-06-30 16:49:58 +08:00
parent e29c999288
commit e965a43c94
2 changed files with 13 additions and 11 deletions

View File

@ -43,16 +43,18 @@ public class LineGraphicDataRepository {
*/
public static void putLineGraph(PublishedGi publishGi) {
try {
LayoutGraphicsProto.RtssGraphicStorage storage =
LayoutGraphicsProto.RtssGraphicStorage.parseFrom(publishGi.getProto());
Map<String, Map<String, ? extends Builder>> lineDataMap = new HashMap<>();
// 构建区段
sectionInitLineGraph(lineDataMap, storage);
// 构建道岔
switchInitLineGraph(lineDataMap, storage);
// 设置公里标
setUpKilometerCode(lineDataMap, storage);
lineGraphMap.put(publishGi.getLineId(), lineDataMap);
if (publishGi.getLineId() != null) {
LayoutGraphicsProto.RtssGraphicStorage storage =
LayoutGraphicsProto.RtssGraphicStorage.parseFrom(publishGi.getProto());
Map<String, Map<String, ? extends Builder>> lineDataMap = new HashMap<>();
// 构建区段
sectionInitLineGraph(lineDataMap, storage);
// 构建道岔
switchInitLineGraph(lineDataMap, storage);
// 设置公里标
setUpKilometerCode(lineDataMap, storage);
lineGraphMap.put(publishGi.getLineId(), lineDataMap);
}
} catch (InvalidProtocolBufferException e) {
log.error("反序列化信息失败", e);
}

@ -1 +1 @@
Subproject commit 2b9ad05b202b3b90c3f64b6b8c8a56ec83716f08
Subproject commit 9a7b4b7a3a912970197155a149a9da463d2a68fc