| | |
| | | // return codeList.stream().map(SortCodeDto::getCode).collect(Collectors.toList()); |
| | | } |
| | | |
| | | public void modifyDynamicMatrix(Integer lev, List<String> codeDataList, String vehicle) { |
| | | this.modifyDynamicMatrix(lev, codeDataList, vehicle, false); |
| | | public void modifyDynamicMatrix(Integer lev, List<int[]> codeIdxList, String vehicle) { |
| | | this.modifyDynamicMatrix(lev, codeIdxList, vehicle, false); |
| | | } |
| | | |
| | | public synchronized void modifyDynamicMatrix(Integer lev, List<String> codeDataList, String vehicle, boolean reset) { |
| | | public synchronized void modifyDynamicMatrix(Integer lev, List<int[]> codeIdxList, String vehicle, boolean reset) { |
| | | if (Cools.isEmpty(vehicle)) { |
| | | return; |
| | | } |
| | |
| | | if (!reset) { |
| | | // long time = System.currentTimeMillis() / 1000; |
| | | int serial = 1; |
| | | for (String codeData : codeDataList) { |
| | | int[] codeMatrixIdx = getCodeMatrixIdx(lev, codeData); |
| | | for (int[] codeMatrixIdx : codeIdxList) { |
| | | dynamicMatrix[codeMatrixIdx[0]][codeMatrixIdx[1]] = new DynamicNode(vehicle, serial); |
| | | serial++; |
| | | } |
| | |
| | | setDynamicMatrix(lev, dynamicMatrix); |
| | | } |
| | | |
| | | public void clearDynamicMatrixByCodeList(Integer lev, List<String> codeDataList) { |
| | | this.modifyDynamicMatrix(lev, codeDataList, DynamicNodeType.ACCESS.val); |
| | | public void clearDynamicMatrixByCodeList(Integer lev, List<int[]> codeIdxList) { |
| | | this.modifyDynamicMatrix(lev, codeIdxList, DynamicNodeType.ACCESS.val); |
| | | } |
| | | |
| | | public int[][] filterMapData(int[][] mapMatrix, Integer lev, List<String> lockNodes) { |