NERoomListener
@objc
public protocol NERoomListener : NEPreviewRoomListener
房间监听协议
-
房间属性变更回调
Declaration
Swift
@objc optional func onRoomPropertiesChanged(properties: [String : String])
-
房间属性删除回调
Declaration
Swift
@objc optional func onRoomPropertiesDeleted(properties: [String : String])
-
成员角色变更通知
添加监听后,有成员角色变更会触发此方法
Declaration
Swift
@objc optional func onMemberRoleChanged(member: NERoomMember, oldRole: NERoomRole, newRole: NERoomRole)
-
成员名称变更
Declaration
Swift
@objc optional func onMemberNameChanged(member: NERoomMember, name: String)
-
成员属性变更回调
Declaration
Swift
@objc optional func onMemberPropertiesChanged(member: NERoomMember, properties: [String: String])
-
成员属性删除回调
Declaration
Swift
@objc optional func onMemberPropertiesDeleted(member: NERoomMember, properties: [String: String])
-
成员加入房间回调
添加监听后,有成员加入房间会触发此方法
Declaration
Swift
@objc optional func onMemberJoinRoom(members: [NERoomMember])
-
成员离开房间回调
添加监听后,有成员离开房间会触发此方法
Declaration
Swift
@objc optional func onMemberLeaveRoom(members: [NERoomMember])
-
房间结束回调
添加监听后,房间结束会触发此方法
Declaration
Swift
@objc optional func onRoomEnded(reason: NERoomEndReason)
-
成员加入音视频频道回调
添加监听后,有成员加入音视频频道会触发此方法
Declaration
Swift
@objc optional func onMemberJoinRtcChannel(members: [NERoomMember])
-
成员离开音视频频带回调
添加监听后,有成员离开音视频频道会触发此方法
Declaration
Swift
@objc optional func onMemberLeaveRtcChannel(members: [NERoomMember])
-
音视频频道出错回调
添加监听后,有音视频频道出错会触发此方法
Declaration
Swift
@objc optional func onRtcChannelError(code: Int)
-
成员加入聊天室回调
添加监听后,有成员加入聊天室会触发此方法
Declaration
Swift
@objc optional func onMemberJoinChatroom(members: [NERoomMember])
-
成员离开聊天室回调
添加监听后,有成员离开聊天室会触发此方法
Declaration
Swift
@objc optional func onMemberLeaveChatroom(members: [NERoomMember])
-
成员音频关闭回调
添加监听后,成员音频状态变更会触发此方法
Declaration
Swift
@objc optional func onMemberAudioMuteChanged(member: NERoomMember, mute: Bool, operateBy: NERoomMember?)
-
成员视频关闭回调
添加监听后,成员视频状态变更会触发此方法
Declaration
Swift
@objc optional func onMemberVideoMuteChanged(member: NERoomMember, mute: Bool, operateBy: NERoomMember?)
-
成员共享状态改变回调
添加监听后,成员屏幕共享状态变更会触发此方法
Declaration
Swift
@objc optional func onMemberScreenShareStateChanged(member: NERoomMember, isSharing: Bool, operateBy: NERoomMember?)
-
房间锁定状态变更
Declaration
Swift
@objc optional func onRoomLockStateChanged(isLocked: Bool)
-
房间直播状态变更
Declaration
Swift
@objc optional func onRoomLiveStateChanged(state: NERoomLiveState)
-
聊天室消息回调
添加监听后,收到聊天室消息会触发此方法
Declaration
Swift
@objc optional func onReceiveChatroomMessages(messages: [NERoomChatMessage])
-
成员白板状态变更回调
添加监听后,成员白板共享状态变更会触发此方法
Declaration
Swift
@objc optional func onMemberWhiteboardStateChanged(member: NERoomMember, isSharing: Bool, operateBy: NERoomMember?)
-
白板异常回调
添加监听后,白板异常会触发此方法
Declaration
Swift
@objc optional func onWhiteboardError(code: Int, message: String)
-
提示房间内谁正在说话及说话这瞬时音量的回调,该回调默认为关闭状态
可通过 [NERoomRtcController enableAudioVolumeIndication] 方法开启 开启后 无论房间内是否有人说话,SDK 都会按设置的时间间隔触发该回调。
- 如果有 [NEMemberVolumeInfo.userUuid] 出现在上次返回的列表中,但不在本次返回的列表中,则默认该 userId 对应的远端用户没有说话。
- 如果 [NEMemberVolumeInfo.volume] 为 0,表示该用户没有说话。
- 如果列表为空,则表示此时远端没有人说话。
Declaration
Swift
@objc optional func onRtcAudioVolumeIndication(volumes: [NEMemberVolumeInfo], totalVolume: Int)
-
本端音频输出设备变更通知,如切换到扬声器、听筒、耳机等
Declaration
Swift
@objc optional func onRtcAudioOutputDeviceChanged(device: NEAudioOutputDevice)