| | |
| | | |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.concurrent.ConcurrentHashMap; |
| | | |
| | | @Component |
| | |
| | | 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); |
| | | } |
| | | } |