|
|
@ -1,59 +0,0 @@ |
|
|
|
package a8k.service.app.app_ctrl_service; |
|
|
|
|
|
|
|
import a8k.type.appret.AppRet; |
|
|
|
import a8k.controler.extapi.utils.ExtApiTab; |
|
|
|
import a8k.controler.extapi.utils.ExtApiFn; |
|
|
|
import a8k.controler.extapi.pagecontrol.ExtApiTabConfig; |
|
|
|
import org.slf4j.Logger; |
|
|
|
import org.springframework.stereotype.Component; |
|
|
|
|
|
|
|
@ExtApiTab(cfg = ExtApiTabConfig.AppCtrlService) |
|
|
|
@Component |
|
|
|
public class AppCtrlService { |
|
|
|
static final Logger logger = org.slf4j.LoggerFactory.getLogger(AppCtrlService.class); |
|
|
|
|
|
|
|
static class ORDER { |
|
|
|
static final int initDevice = 1; |
|
|
|
static final int shutdown = 2; |
|
|
|
static final int startProcess = 3; |
|
|
|
static final int pauseProcess = 4; |
|
|
|
static final int forceStopProcess = 5; |
|
|
|
static final int stopProcess = 6; |
|
|
|
} |
|
|
|
|
|
|
|
@ExtApiFn(name = "初始化设备", group = "设备基础控制", order = ORDER.initDevice) |
|
|
|
public AppRet<Object> initDevice() { |
|
|
|
return AppRet.success(); |
|
|
|
} |
|
|
|
|
|
|
|
//关机 |
|
|
|
@ExtApiFn(name = "关机", group = "设备基础控制", order = ORDER.shutdown) |
|
|
|
public AppRet<Object> shutdown() { |
|
|
|
return AppRet.success(); |
|
|
|
} |
|
|
|
|
|
|
|
//启动 |
|
|
|
@ExtApiFn(name = "启动", group = "应用控制", order = ORDER.startProcess) |
|
|
|
public AppRet<Object> startProcess() { |
|
|
|
return AppRet.success(); |
|
|
|
} |
|
|
|
|
|
|
|
//暂停 |
|
|
|
@ExtApiFn(name = "暂停", group = "应用控制", order = ORDER.pauseProcess) |
|
|
|
public AppRet<Object> pauseProcess() { |
|
|
|
return AppRet.success(); |
|
|
|
} |
|
|
|
|
|
|
|
//急停 |
|
|
|
@ExtApiFn(name = "急停", group = "应用控制", order = ORDER.forceStopProcess) |
|
|
|
public AppRet<Object> forceStopProcess() { |
|
|
|
return AppRet.success(); |
|
|
|
} |
|
|
|
|
|
|
|
//停止 |
|
|
|
@ExtApiFn(name = "停止", group = "应用控制", order = ORDER.stopProcess) |
|
|
|
public AppRet<Object> stopProcess() { |
|
|
|
return AppRet.success(); |
|
|
|
} |
|
|
|
|
|
|
|
} |