Hi I am using ROOM DB for KMP Compose Versions : ...
# multiplatform
s
Hi I am using ROOM DB for KMP Compose Versions :
Copy code
#room
room = "2.7.0-alpha10"
ksp = "2.0.20-1.0.25"
sqlite = "2.5.0-SNAPSHOT"
material3Android = "1.3.1"
Copy code
@Database(
    entities = [Person::class,PartnerResourceEntity::class,ProductEntity::class,TicketEntity::class],
    version = 1
)

@ConstructedBy(AppDatabaseConstructor::class)
abstract class AppDatabase : RoomDatabase() {
    abstract fun personDao(): PersonDao // To be deleted Sample
    abstract fun partnerResourceDao(): PartnerResourceDao
    abstract fun productDao(): ProductDao
    abstract fun ticketDao():TicketDao
}


// ROOM internally handles the platform specific implementations
@Suppress("NO_ACTUAL_FOR_EXPECT")
expect object AppDatabaseConstructor : RoomDatabaseConstructor<AppDatabase> {
    override fun initialize(): AppDatabase
}
Can anyone help me know how to get clearAllTables() method ? I have seen in some threads that they removed it ? Thanks in advance
s
No In this also they are using clearAllTables internal method of room which they have removed for common code I guess. Do you know any KMP ( Compose ) Solution
a
you can copy the generated code for android source set