|
|
@ -1,6 +1,5 @@
|
|
|
|
package com.xydl.cac.controller;
|
|
|
|
package com.xydl.cac.controller;
|
|
|
|
|
|
|
|
|
|
|
|
import com.xydl.cac.iec.IecClient;
|
|
|
|
|
|
|
|
import com.xydl.cac.model.Response;
|
|
|
|
import com.xydl.cac.model.Response;
|
|
|
|
import com.xydl.cac.model.StaticVariable;
|
|
|
|
import com.xydl.cac.model.StaticVariable;
|
|
|
|
import com.xydl.cac.service.IcdFileConfigService;
|
|
|
|
import com.xydl.cac.service.IcdFileConfigService;
|
|
|
@ -40,9 +39,28 @@ public class TestController extends BasicController {
|
|
|
|
webSocketServer.sendMessage(msg, warningId);
|
|
|
|
webSocketServer.sendMessage(msg, warningId);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@GetMapping("realTimeMap")
|
|
|
|
@GetMapping("realTimeClientMap")
|
|
|
|
@ApiOperation("实时订阅Map")
|
|
|
|
@ApiOperation("realTimeClientMap")
|
|
|
|
public Response<HashMap<Integer, IecClient>> realTimeMap() {
|
|
|
|
public Response<HashMap> realTimeClientMap() {
|
|
|
|
return Response.success(StaticVariable.realTimeClientMap);
|
|
|
|
return Response.success(StaticVariable.realTimeClientMap);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@GetMapping("paramRelationMap")
|
|
|
|
|
|
|
|
@ApiOperation("paramRelationMap")
|
|
|
|
|
|
|
|
public Response<HashMap> paramRelationMap() {
|
|
|
|
|
|
|
|
return Response.success(StaticVariable.paramRelationMap);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@GetMapping("sensorLastDataMap")
|
|
|
|
|
|
|
|
@ApiOperation("sensorLastDataMap")
|
|
|
|
|
|
|
|
public Response<HashMap> sensorLastDataMap() {
|
|
|
|
|
|
|
|
return Response.success(StaticVariable.sensorLastDataMap);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@GetMapping("clearMap")
|
|
|
|
|
|
|
|
@ApiOperation("clearMap")
|
|
|
|
|
|
|
|
public void clearMap() {
|
|
|
|
|
|
|
|
StaticVariable.sensorLastDataMap.clear();
|
|
|
|
|
|
|
|
StaticVariable.paramRelationMap.clear();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|