Occupancy

interface Occupancy

This interface is used to interact with occupancy in a chat room: subscribing to occupancy updates and fetching the current room occupancy metrics.

Get an instance via Room.occupancy.

Not suitable for inheritance

This interface is not designed for implementation or extension outside this SDK. The interface definition may evolve over time with additional properties or methods to support new features, which could break implementations.

Properties

Link copied to clipboard
abstract val current: OccupancyData?

The latest occupancy data received from realtime events.

Functions

Link copied to clipboard
Link copied to clipboard
abstract suspend fun get(): OccupancyData

Get the current occupancy of the chat room.

Link copied to clipboard
abstract fun subscribe(listener: OccupancyListener): Subscription

Subscribe a given listener to occupancy updates of the chat room.