这是我第一次尝试将Realm用作本地数据存储,但遇到了我不理解的编译错误。在其他任何地方,我都找不到该错误的任何参考。发生了什么事?
import android.bluetooth.BluetoothDevice
import io.realm.RealmObject
import io.realm.annotations.PrimaryKey
import io.realm.annotations.RealmClass
@RealmClass
open class DeviceItem(
@PrimaryKey var id: Long = 0,
var device: BluetoothDevice? = null,
var deviceName: String= "",
var address: String = "",
connected: String = ""
) : RealmObject() {
var connected: Boolean = false
set
init {
this.connected = connected === "true"
}
}
错误:
warning: Unclosed files for the types '[io.realm.ca_test_test_DeviceItemRealmProxy]'; these types will not undergo annotation processing