LiveSeatStore provides a complete set of seat management APIs, including taking seat, leaving seat, locking seat, unlocking seat, kicking user off seat, remote device control, etc. Through this class, seat management functionality can be implemented in the live room.LiveSeatStore instance, passing a valid live room ID.Property | Type | Description |
seatList | Seat list. | |
canvas | Canvas information. | |
speakingUsers | StateFlow<MutableMap<String, Int>> | Speaking users. |
avStatistics | Audio and video statistics. |
Function | Description |
Create seat management instance. | |
Seat event callbacks. | |
Seat event callbacks. | |
Take seat. | |
Leave seat. | |
Lock seat. | |
Unlock seat. | |
Kick user off seat. | |
Move user. | |
Set a featured host. | |
Revoke a featured host. | |
Open remote camera. | |
Close remote camera. | |
Open remote microphone. | |
Close remote microphone. |
abstract fun addLiveSeatEventListener(listener: LiveSeatListener?)
Parameter | Type | Description |
listener | Listener. |
abstract fun removeLiveSeatEventListener(listener: LiveSeatListener?)
Parameter | Type | Description |
listener | Listener. |
abstract fun takeSeat(seatIndex: Int,completion: CompletionHandler?)
Parameter | Type | Description |
seatIndex | Int | Seat index. |
completion | Completion callback. |
abstract fun leaveSeat(completion: CompletionHandler?)
Parameter | Type | Description |
completion | Completion callback. |
abstract fun lockSeat(seatIndex: Int,completion: CompletionHandler?)
Parameter | Type | Description |
seatIndex | Int | Seat index. |
completion | Completion callback. |
abstract fun unlockSeat(seatIndex: Int,completion: CompletionHandler?)
Parameter | Type | Description |
seatIndex | Int | Seat index. |
completion | Completion callback. |
abstract fun kickUserOutOfSeat(userID: String?,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String? | User ID. |
completion | Completion callback. |
abstract fun moveUserToSeat(userID: String?,targetIndex: Int,policy: MoveSeatPolicy? = MoveSeatPolicy.ABORT_WHEN_OCCUPIED,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String? | User ID. |
targetIndex | Int | Target seat index. |
policy | Move policy. | |
completion | Completion callback. |
abstract fun setFeaturedHost(userID: String,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String | User ID. |
completion | Completion callback. |
abstract fun revokeFeaturedHost(userID: String,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String | User ID. |
completion | Completion callback. |
abstract fun openRemoteCamera(userID: String?,policy: DeviceControlPolicy,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String? | User ID. |
policy | Device control policy. | |
completion | Completion callback. |
abstract fun closeRemoteCamera(userID: String?,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String? | User ID. |
completion | Completion callback. |
abstract fun openRemoteMicrophone(userID: String?,policy: DeviceControlPolicy,completion: CompletionHandler?)
Parameter | Type | Description |
userID | String? | User ID. |
policy | Device control policy. | |
completion | Completion callback. |
abstract fun closeRemoteMicrophone(userID: String?,completion: CompletionHandler?)internal val hasAudioStreamUserList: MutableSet<String> = mutableSetOf()internal val hasVideoStreamUserList: MutableSet<String> = mutableSetOf()
Parameter | Type | Description |
userID | String? | User ID. |
completion | Completion callback. |
Enum Value | Description |
ABORT_WHEN_OCCUPIED | Abort when occupied. |
FORCE_REPLACE | Force replace. |
SWAP_POSITION | Swap position. |
Enum Value | Description |
UNLOCK_ONLY | Unlock only. |
Enum Value | Description |
NONE | Not suspended. |
IN_BACKGROUND | User suspended in background. |
IN_CALLING | User is on a phone call. |
Method | Description |
onLocalCameraOpenedByAdmin | Triggered when the local camera is opened by an admin. |
onLocalCameraClosedByAdmin | Triggered when the local camera is closed by an admin. |
onLocalMicrophoneOpenedByAdmin | Triggered when the local microphone is opened by an admin. |
onLocalMicrophoneClosedByAdmin | Triggered when the local microphone is closed by an admin. |
Property | Type | Description |
userID | String | User ID. |
userName | String | User name. |
avatarURL | String | Avatar URL. |
role | User role. | |
liveID | String | Live room ID. |
microphoneStatus | Microphone status. | |
allowOpenMicrophone | Boolean | Whether microphone can be opened. |
cameraStatus | Camera status. | |
allowOpenCamera | Boolean | Whether camera can be opened. |
userSuspendStatus | User suspend status. |
Property | Type | Description |
x | Int | X coordinate. |
y | Int | Y coordinate. |
w | Int | Width. |
h | Int | Height. |
zorder | Int | Z-order. |
Property | Type | Description |
userID | String | User ID. |
videoBitrate | Int | Local video bitrate. |
videoWidth | Int | Local video width. |
videoHeight | Int | Local video height. |
frameRate | Int | Local video frame rate. |
audioSampleRate | Int | Audio sample rate. |
audioBitrate | Int | Audio bitrate. |
Property | Type | Description |
index | Int | Seat index. |
isLocked | Boolean | Whether locked. |
userInfo | User information. | |
region | Region information. | |
isFeaturedHost | Boolean | Whether the user on this seat is currently a featured host. Can only be true in templates that support featured host slots. |
Property | Type | Description |
w | Int | Width. |
h | Int | Height. |
templateID | Int | Template ID. |
Property | Type | Description |
seatList | Seat list. | |
canvas | Canvas information. | |
speakingUsers | StateFlow<MutableMap<String, Int>> | Speaking users. |
avStatistics | Audio and video statistics. |
フィードバック