val config = RealmConfiguration.Builder() ...
# android
t
val config = RealmConfiguration.Builder() .schemaVersion(1) .deleteRealmIfMigrationNeeded() .migration(MyMigration()) .build() Realm.setDefaultConfiguration(config)
m
You can't use
deleteRealmIfMigrationNeeded()
and
migration()
at the same time. But this is more a Realm question, rather than Kotlin
m
I'm agree with @mgaetan89 is more related with Realm, and I misunderstood the question, I just believe you want to migrate code to Kotlin, for that reason I sent you a link with Realm Kotlin example.
t
I already made it work
tnx
b
use
deleteRealmIfMigrationNeeded
just in case if you don't want to make a Realm Migration Schema
t
ok tnx @budioktaviyan