[*] 日常优化

This commit is contained in:
acgist
2023-08-11 08:10:09 +08:00
parent 6336bb4767
commit d65fe5b27f
6 changed files with 184 additions and 128 deletions

View File

@@ -37,5 +37,6 @@
* 存在TURN服务优先使用
* 安卓关闭视频没有删除预览
* 浏览器WebRTC监控页面关闭`chrome://webrtc-internals/`
* me -> this
## 完成任务

View File

@@ -885,6 +885,12 @@ class Taoyao extends RemoteClient {
case "platform::error":
me.callbackError(message);
break;
case "platform::reboot":
me.defaultPlatformReboot(message);
break;
case "platform::shutdown":
me.defaultPlatformShutdown(message);
break;
}
}
@@ -1954,6 +1960,55 @@ class Taoyao extends RemoteClient {
console.debug("视频方向变化信令", message);
}
/**
* 重启平台信令
*
* @returns 响应
*/
async platformReboot() {
return await this.request(protocol.buildMessage("platform::reboot", {}));
}
/**
* 重启平台信令
*
* @param {*} message 信令消息
*/
defaultPlatformReboot(message) {
console.debug("平台重启", message);
}
/**
* 执行命令信令
*
* @param {*} script 命令
*
* @returns 响应
*/
async platformScript(script) {
return await this.request(protocol.buildMessage("platform::script", {
script
}));
}
/**
* 关闭平台信令
*
* @returns 响应
*/
async platformShutdown() {
return await this.request(protocol.buildMessage("platform::shutdown", {}));
}
/**
* 关闭平台信令
*
* @param {*} message 信令消息
*/
defaultPlatformShutdown(message) {
console.debug("平台关闭", message);
}
/**
* 消费媒体信令
*

View File

@@ -33,7 +33,7 @@ import lombok.extern.slf4j.Slf4j;
}
"""
},
flow = "终端->信令服务->终端"
flow = "终端=>信令服务"
)
public class PlatformScriptProtocol extends ProtocolClientAdapter {