Class
ObservableRoom
@available(*, deprecated, message: "Room is now an ObservableObject which can be observed directly.")
open class ObservableRoom: ObservableObject, RoomDelegate, Loggable
Relationships
Conforms To
Loggable
Allows to extend with custom
log
method which automatically captures current type (class name).RoomDelegate
ObservableObject
Initializers
Properties
connectionState
public var connectionState: ConnectionState
metadata
public var metadata: String?
remoteParticipants
public var remoteParticipants: [Sid: ObservableParticipant]
allParticipants
public var allParticipants: [Sid: ObservableParticipant]
cameraTrackState
@Published public var cameraTrackState: TrackPublishState
microphoneTrackState
@Published public var microphoneTrackState: TrackPublishState
Methods
switchCameraPosition()
@discardableResult
public func switchCameraPosition() -> Promise<Bool>
toggleCameraEnabled()
public func toggleCameraEnabled()
toggleMicrophoneEnabled()
public func toggleMicrophoneEnabled()
room(_:didUpdate:oldValue:)
open func room(_ room: Room, didUpdate connectionState: ConnectionState, oldValue: ConnectionState)
room(_:participantDidJoin:)
open func room(_ room: Room,
participantDidJoin participant: RemoteParticipant)
room(_:participantDidLeave:)
open func room(_ room: Room,
participantDidLeave participant: RemoteParticipant)
room(_:participant:didUpdate:)
open func room(_ room: Room, participant: Participant, didUpdate metadata: String?)
room(_:didConnect:)
open func room(_ room: Room, didConnect isReconnect: Bool)
room(_:didFailToConnect:)
open func room(_ room: Room, didFailToConnect error: Error)
room(_:didDisconnect:)
open func room(_ room: Room, didDisconnect error: Error?)
room(_:didUpdate:)
open func room(_ room: Room, didUpdate speakers: [Participant])
room(_:didUpdate:)
open func room(_ room: Room, didUpdate metadata: String?)
room(_:participant:didUpdate:)
open func room(_ room: Room, participant: Participant, didUpdate connectionQuality: ConnectionQuality)
room(_:participant:didUpdate:muted:)
open func room(_ room: Room, participant: Participant, didUpdate publication: TrackPublication, muted: Bool)
room(_:participant:didUpdate:)
open func room(_ room: Room, participant: Participant, didUpdate permissions: ParticipantPermissions)
room(_:participant:didUpdate:streamState:)
open func room(_ room: Room, participant: RemoteParticipant, didUpdate publication: RemoteTrackPublication, streamState: StreamState)
room(_:participant:didPublish:)
open func room(_ room: Room, participant: RemoteParticipant, didPublish publication: RemoteTrackPublication)
room(_:participant:didUnpublish:)
open func room(_ room: Room, participant: RemoteParticipant, didUnpublish publication: RemoteTrackPublication)
room(_:participant:didSubscribe:track:)
open func room(_ room: Room, participant: RemoteParticipant, didSubscribe publication: RemoteTrackPublication, track: Track)
room(_:participant:didFailToSubscribe:error:)
open func room(_ room: Room, participant: RemoteParticipant, didFailToSubscribe trackSid: String, error: Error)
room(_:participant:didUnsubscribe:track:)
open func room(_ room: Room, participant: RemoteParticipant, didUnsubscribe publication: RemoteTrackPublication, track: Track)
room(_:participant:didReceive:)
open func room(_ room: Room, participant: RemoteParticipant?, didReceive data: Data)
room(_:localParticipant:didPublish:)
open func room(_ room: Room, localParticipant: LocalParticipant, didPublish publication: LocalTrackPublication)
room(_:localParticipant:didUnpublish:)
open func room(_ room: Room, localParticipant: LocalParticipant, didUnpublish publication: LocalTrackPublication)
room(_:participant:didUpdate:permission:)
open func room(_ room: Room, participant: RemoteParticipant, didUpdate publication: RemoteTrackPublication, permission allowed: Bool)