ThreadsRepository

Repository for read/write operations related to threads.

Inheritors

Functions

Link copied to clipboard
abstract suspend fun clear()

Deletes all data related to threads.

Link copied to clipboard
abstract suspend fun deleteChannelThreads(cid: String)

Deletes all threads from a channel.

Link copied to clipboard
abstract suspend fun insertThreadOrder(id: String, order: List<String>)

Inserts the order in which local threads should be displayed.

Link copied to clipboard
abstract suspend fun insertThreads(threads: List<Thread>)

Inserts the given list of Thread.

Link copied to clipboard
abstract suspend fun selectThread(id: String): Thread?

Retrieves the Thread identified by id.

Link copied to clipboard
abstract suspend fun selectThreadOrder(id: String): List<String>

Retrieves the order in which local threads should be displayed.

Link copied to clipboard
abstract suspend fun selectThreads(ids: List<String>): List<Thread>

Retrieves all Threads identified by the supplied ids.

Link copied to clipboard
abstract suspend fun upsertMessageInThread(message: Message)

Upsert a Message in the corresponding thread (if such exists).

Link copied to clipboard
abstract suspend fun upsertMessagesInThread(messages: List<Message>)

Upsert a list of Messages in the corresponding thread (if such exists).