You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

21 lines
568 B

package com.keylesspalace.tusky.db
import androidx.room.*
@Entity(
primaryKeys = ["localId", "chatId"]
)
data class ChatEntity (
val localId: Long, /* our user account id */
val chatId: String,
val accountId: String,
val unread: Long,
val updatedAt: Long,
val lastMessageId: String?
)
data class ChatEntityWithAccount (
@Embedded val chat: ChatEntity,
@Embedded(prefix = "a_") val account: TimelineAccountEntity?,
@Embedded(prefix = "msg_") val lastMessage: ChatMessageEntity? = null
)