Package-level declarations

State functions for room/participants to use within composables.

Types

Link copied to clipboard
Link copied to clipboard
data class ParticipantInfo(val name: String?, val identity: Participant.Identity?, val metadata: String?)

Holder for basic Participant information.

Link copied to clipboard
data class RoomInfo(val name: String?, val metadata: String?)

Holder for basic Room information.

Link copied to clipboard
data class VoiceAssistant(val agent: RemoteParticipant?, val state: AgentState, val audioTrack: TrackReference?, val agentTranscriptions: List<TranscriptionSegment>, val agentAttributes: Map<String, String>?)

Functions

Link copied to clipboard
fun Room.getTrackReferences(sources: List<Track.Source>, usePlaceholders: Set<Track.Source> = emptySet(), onlySubscribed: Boolean = true): List<TrackReference>
Link copied to clipboard
fun Participant.getTrackReferencesBySource(sources: List<Track.Source>, usePlaceholders: Set<Track.Source> = emptySet(), onlySubscribed: Boolean = true): List<TrackReference>
Link copied to clipboard
fun rememberAgentState(participant: Participant?): AgentState

Keeps track of the agent state for a participant.

Link copied to clipboard
fun rememberConnectionState(passedRoom: Room? = null): Room.State

Returns the Room.State from passedRoom or the local RoomScope if null.

Link copied to clipboard
fun rememberParticipantInfo(passedParticipant: Participant? = null): ParticipantInfo

Remembers the participant info and updates whenever it is changed.

Link copied to clipboard
fun rememberParticipants(passedRoom: Room? = null): List<Participant>

Remembers the full list of participants, with the local participant included as the first item in the list.

Link copied to clipboard
fun rememberParticipantTrackReferences(sources: List<Track.Source> = listOf( Track.Source.CAMERA, Track.Source.SCREEN_SHARE ), usePlaceholders: Set<Track.Source> = emptySet(), passedParticipant: Participant? = null, onlySubscribed: Boolean = true): List<TrackReference>
fun rememberParticipantTrackReferences(sources: List<Track.Source>, participantIdentity: Participant.Identity? = null, passedRoom: Room? = null, usePlaceholders: Set<Track.Source> = emptySet(), onlySubscribed: Boolean = true): List<TrackReference>

Returns an array of TrackReferences for a participant depending the sources provided.

Link copied to clipboard
fun rememberRoomInfo(passedRoom: Room? = null): RoomInfo

Remembers the room info and updates whenever it is changed.

Link copied to clipboard
fun <T : Track> rememberTrack(trackIdentifier: TrackIdentifier): T?

Observes the trackIdentifier object for the track.

Link copied to clipboard
Link copied to clipboard
fun rememberTracks(sources: List<Track.Source> = listOf( Track.Source.CAMERA, Track.Source.SCREEN_SHARE ), usePlaceholders: Set<Track.Source> = emptySet(), passedRoom: Room? = null, onlySubscribed: Boolean = true): List<TrackReference>

Returns an array of TrackReferences depending the sources provided.

Link copied to clipboard
fun rememberVoiceAssistant(passedRoom: Room? = null): VoiceAssistant

This looks for the first agent-participant in the room.