| | |
| | | package com.fzzy.gateway.hx2023.service; |
| | | |
| | | import com.bstek.dorado.annotation.Expose; |
| | | import com.fzzy.api.data.GatewayDeviceType; |
| | | import com.fzzy.gateway.api.GatewayRemoteManager; |
| | | import com.fzzy.gateway.api.GatewayRemoteService; |
| | | import com.fzzy.gateway.data.BaseReqData; |
| | | import com.fzzy.gateway.entity.GatewayConf; |
| | | import com.fzzy.gateway.entity.GatewayDevice; |
| | | import com.fzzy.gateway.service.GatewayConfService; |
| | | |
| | | |
| | |
| | | public void updateDeviceCache() { |
| | | deviceService.flushCache(); |
| | | } |
| | | |
| | | public void initAllLpr() { |
| | | List<GatewayDevice> list = deviceService.listAll(); |
| | | |
| | | if (null == list || list.isEmpty()) { |
| | | return; |
| | | } |
| | | |
| | | BaseReqData reqData; |
| | | int i = 1; |
| | | for (GatewayDevice device : list) { |
| | | |
| | | if (!GatewayDeviceType.TYPE_02.getCode().equals(device.getType())) { |
| | | continue; |
| | | } |
| | | |
| | | reqData = new BaseReqData(device); |
| | | reqData.setIndex(i); |
| | | gatewayRemoteManager.getSyncLprService(device.getSyncProtocol()).initLpr(reqData); |
| | | i++; |
| | | } |
| | | } |
| | | } |