Rooms

interface Rooms

Manages the lifecycle of chat rooms.

Properties

Link copied to clipboard

Get the chat client options used to create the Chat instance.

Functions

Link copied to clipboard
abstract suspend fun get(roomId: String, options: RoomOptions = buildRoomOptions()): Room

Gets a room reference by ID. The Rooms class ensures that only one reference exists for each room. A new reference object is created if it doesn't already exist, or if the one used previously was released using release(roomId).

Link copied to clipboard
suspend fun Rooms.get(roomId: String, initOptions: MutableRoomOptions.() -> Unit): Room

Spec: CHA-RC4

Link copied to clipboard
abstract suspend fun release(roomId: String)

Release the Room object if it exists. This method only releases the reference to the Room object from the Rooms instance and detaches the room from Ably. It does not unsubscribe to any events.