mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 12:07:28 +00:00
Room/Timeline: simplify the apis
This commit is contained in:
+2
@@ -61,6 +61,8 @@ interface MatrixRoom : Closeable {
|
||||
|
||||
fun timeline(): MatrixTimeline
|
||||
|
||||
fun open(): Result<Unit>
|
||||
|
||||
suspend fun userDisplayName(userId: UserId): Result<String?>
|
||||
|
||||
suspend fun userAvatarUrl(userId: UserId): Result<String?>
|
||||
|
||||
+1
-13
@@ -28,20 +28,8 @@ interface MatrixTimeline {
|
||||
)
|
||||
|
||||
fun paginationState(): StateFlow<PaginationState>
|
||||
|
||||
fun timelineItems(): Flow<List<MatrixTimelineItem>>
|
||||
|
||||
suspend fun paginateBackwards(requestSize: Int, untilNumberOfItems: Int): Result<Unit>
|
||||
fun initialize()
|
||||
fun dispose()
|
||||
|
||||
/**
|
||||
* @param message markdown message
|
||||
*/
|
||||
suspend fun sendMessage(message: String): Result<Unit>
|
||||
|
||||
suspend fun editMessage(originalEventId: EventId, message: String): Result<Unit>
|
||||
|
||||
suspend fun replyMessage(inReplyToEventId: EventId, message: String): Result<Unit>
|
||||
|
||||
suspend fun fetchDetailsForEvent(eventId: EventId): Result<Unit>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user