通知事件处理
接口描述
配置OpenEyeCall通用事件通知处理函数。
注意事项
已经建立与OpenEyeCall的WebSocket连接。
方法定义
OpenEyeCall.prototype.SetComNotifyCallBack = function(callbacks)
参数描述
|
参数名 |
类型 |
可选/必选 |
描述 |
|---|---|---|---|
|
callbacks |
Callback |
必选 |
回调方法集合。 |
|
参数名 |
类型 |
可选/必选 |
描述 |
|---|---|---|---|
|
onNotify |
function |
必选 |
通知事件处理方法。 |
|
参数名 |
类型 |
描述 |
|---|---|---|
|
description |
String |
事件描述。 |
|
notify |
Number |
事件编号。 |
|
param |
Param |
事件内容。 |
使用示例
function SetComNotifyCallBack() {
global_openEye_SDK.openEyeCall.SetComNotifyCallBack({onNotify: commonNotified});
}
function commonNotified(data) {
console.info(data);
}