MultiStreamObserver

interface MultiStreamObserver

The interface of multi stream. Client should implement this interface to support the multi-stream feature.

Since

2.0.0

Types

Link copied to clipboard

Base class for the event of an AuxStreamChangedEvent

Link copied to clipboard
interface AuxStreamChangedEvent : CallObserver.CallEvent

Interface for an auxiliary stream changed event

Link copied to clipboard
class AuxStreamClosedEvent(    call: Call,     renderView: <Error class: unknown class>,     error: String?) : MultiStreamObserver.AbstractAuxStreamChangedEvent

This will be triggered when auxiliary stream is closed successfully or unsuccessfully. On this event, the client can display the view

Link copied to clipboard
class AuxStreamOpenedEvent(    call: Call,     renderView: <Error class: unknown class>,     error: String?) : MultiStreamObserver.AbstractAuxStreamChangedEvent

This will be triggered when auxiliary stream is opened successfully or unsuccessfully. On this event, the client can hide the view

Link copied to clipboard
class AuxStreamPersonChangedEvent(    call: Call?,     auxStream: AuxStream?,     from: CallMembership?,     to: CallMembership?) : MultiStreamObserver.AbstractAuxStreamChangedEvent

This will be triggered when the person represented this auxiliary stream is changed

Link copied to clipboard
class AuxStreamSendingVideoEvent(call: Call?, auxStream: AuxStream?) : MultiStreamObserver.AbstractAuxStreamChangedEvent

This will be triggered when the network is unstable or the represented person muted or unmuted his video, and client can get the detail from the property

Link copied to clipboard
class AuxStreamSizeChangedEvent(call: Call?, auxStream: AuxStream?) : MultiStreamObserver.AbstractAuxStreamChangedEvent

This will be triggered when the auxiliary stream view size is changed, and client can get the detail from the property

Functions

Link copied to clipboard
abstract fun onAuxStreamAvailable(): <Error class: unknown class>?

Callback of SDK when there is a new available auxiliary stream. Client should give SDK a view handle for rendering, and the AuxStreamOpenedEvent would be triggered indicating whether the stream is successfully opened. If the client don't want to open stream at this time, return null

Link copied to clipboard
abstract fun onAuxStreamChanged(event: MultiStreamObserver.AuxStreamChangedEvent?)

Callback when an auxiliary stream is changed

Link copied to clipboard
abstract fun onAuxStreamUnavailable(): <Error class: unknown class>?

Callback of SDK when there is a auxiliary stream unavailable. Client should give SDK a view which will be closed or if the given view is null, SDK will automatically close the last opened stream if needed.