From 59ef6e67d3a1357c19039527dac47747e2ac20fe Mon Sep 17 00:00:00 2001 From: 648540858 <648540858@qq.com> Date: 星期四, 17 三月 2022 10:29:49 +0800 Subject: [PATCH] 统一国标设备与级联平台字符集的使用 --- src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java | 17 +++++++++++++++++ 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java b/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java index a027486..62a45d5 100644 --- a/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java +++ b/src/main/java/com/genersoft/iot/vmp/gb28181/bean/SubscribeHolder.java @@ -2,6 +2,8 @@ import org.springframework.stereotype.Component; +import java.util.ArrayList; +import java.util.List; import java.util.concurrent.ConcurrentHashMap; @Component @@ -34,4 +36,19 @@ public void removeMobilePositionSubscribe(String platformId) { mobilePositionMap.remove(platformId); } + + public List<String> getAllCatalogSubscribePlatform() { + List<String> platforms = new ArrayList<>(); + if(catalogMap.size() > 0) { + for (String key : catalogMap.keySet()) { + platforms.add(catalogMap.get(key).getId()); + } + } + return platforms; + } + + public void removeAllSubscribe(String platformId) { + mobilePositionMap.remove(platformId); + catalogMap.remove(platformId); + } } -- Gitblit v1.8.0