RoomContainer

interface RoomContainer

This module is used to manage a room container A room container can hold some rooms

Functions

addRoomsToContainer
Link copied to clipboard
abstract fun addRoomsToContainer(containerId: String, roomIds: List<String>, listener: IRoomContainerProxy.IAddOrDeleteRoomsToContainerListener? = null)
Adds all of the room of the specified list of room ids to the container identified by the containerId
createContainer
Link copied to clipboard
abstract fun createContainer(name: String, description: String? = null, roomIds: List<String>? = null, listener: IRoomContainerProxy.ICreateContainerListener? = null)
Creates a container with the specified parametersThe name of the container must be unique, otherwise the error code ContainersError.DUPLICATE_CONTAINER_NAME is returned in the ICreateContainerListener.
deleteContainer
Link copied to clipboard
abstract fun deleteContainer(containerId: String, listener: IRoomContainerProxy.IDeleteContainerListener? = null)
Deletes a container identified by the given containerId
deleteContainers
Link copied to clipboard
abstract fun deleteContainers(containerIds: List<String>, listener: IRoomContainerProxy.IDeleteContainersListener? = null)
Deletes containers identified by the given list of container id
fetchContainerById
Link copied to clipboard
abstract fun fetchContainerById(containerId: String, listener: IRoomContainerProxy.IFetchContainerListener? = null)
Fetch a container identified by the given containerId on the server
fetchContainers
Link copied to clipboard
abstract fun fetchContainers(limit: Int = 100, offset: Int = 0, sortOrder: Int = 1, listener: IRoomContainerProxy.IFetchContainersListener? = null)
Fetch a container list on the server
getContainerById
Link copied to clipboard
abstract fun getContainerById(containerId: String): Container?
Returns the container corresponding to the given containerId, or null if such id is not present in the list
moveRooms
Link copied to clipboard
abstract fun moveRooms(oldContainerId: String, newContainerId: String, roomIds: List<String>, listener: IRoomContainerProxy.IAddOrDeleteRoomsToContainerListener? = null)
Moves all of the room of the specified list of room ids from a container to another
removeRoomsToContainer
Link copied to clipboard
abstract fun removeRoomsToContainer(containerId: String, roomIds: List<String>, listener: IRoomContainerProxy.IAddOrDeleteRoomsToContainerListener? = null)
Removes all of the room of the specified list of room ids to the container identified by the containerId
updateContainer
Link copied to clipboard
abstract fun updateContainer(containerId: String, newName: String, newDescription: String? = null, listener: IRoomContainerProxy.IUpdateContainerListener?)
Updates a container identified by the given containerIdThe same rules applies as the container creation

Properties

containers
Link copied to clipboard
abstract val containers: MutableList<Container>
The list of the containers fetched on the server Automatically updated when a container is created or deleted on another platform
containersAsLiveData
Link copied to clipboard
abstract val containersAsLiveData: LiveData<List<Container>>
An observable LiveData of the containers list