| | |
| | | |
| | | public static ApiCommonDevice getCommonDeviceCache(String sn) { |
| | | if (null == sn) return null; |
| | | log.info("在线设备:" + JSON.toJSONString(contextDeviceMap)); |
| | | //log.info("在线设备:" + JSON.toJSONString(contextDeviceMap)); |
| | | return contextDeviceMap.get(sn); |
| | | } |
| | | |
| | |
| | | if (null == ip) return null; |
| | | |
| | | if (contextDeviceMap.isEmpty()) return null; |
| | | log.info("在线设备:" + JSON.toJSONString(contextDeviceMap)); |
| | | //log.info("在线设备:" + JSON.toJSONString(contextDeviceMap)); |
| | | for (ApiCommonDevice device : contextDeviceMap.values()) { |
| | | if (ip.equals(device.getIp())) return device; |
| | | } |