fun initialData(callback: InitialDataCallback): S

Writes initial data to the Realm file. This callback will be executed only once, when the database file is created. This also include cases where RealmConfiguration.Builder.deleteRealmIfMigrationNeeded was set causing the file to be deleted.

The callback will happen on the same thread used when using Realm.writeBlocking.



callback used to write data to the Realm file.