ThreadsLocalService

interface ThreadsLocalService

This interface defines methods to interact with thread related features. It's the local threads implementation and assumes that the homeserver do not support threads

Functions

Link copied to clipboard
abstract fun getAllThreads(): List<TimelineEvent>

Returns a list of all the thread root TimelineEvents that exists at the room level.

Link copied to clipboard
abstract fun getAllThreadsLive(): LiveData<List<TimelineEvent>>

Returns a LiveData list of all the thread root TimelineEvents that exists at the room level.

Link copied to clipboard
abstract fun getMarkedThreadNotifications(): List<TimelineEvent>

Returns a list of all the marked unread threads that exists at the room level.

Link copied to clipboard
abstract fun getMarkedThreadNotificationsLive(): LiveData<List<TimelineEvent>>

Returns a LiveData list of all the marked unread threads that exists at the room level.

Link copied to clipboard
abstract fun isUserParticipatingInThread(rootThreadEventId: String): Boolean

Returns whether or not the current user is participating in the thread.

Link copied to clipboard
abstract fun mapEventsWithEdition(threads: List<TimelineEvent>): List<TimelineEvent>

Enhance the provided root thread TimelineEvent List by adding the latest message edition for that thread.

Link copied to clipboard
abstract suspend fun markThreadAsRead(rootThreadEventId: String)

Marks the current thread as read in local DB. note: read receipts within threads are not yet supported with the API