它是可能排除某些类型从 copyFromRealm 的结果吗?
例如上课
open class City : RealmObject() {
var id : String? = null
var name : String? = null
var streets : RealmList<Street>? = null
}
我想要得到的非托管对象的列表,但我不要街道被列入这一结果。
使用 Realm.copyFromRealm(Iterable<E> realmObjects, int maxDepth)
和使用 0
为 maxDepth
。看到医生在这里。
City unmanagedCity = realm.copytFromRealm(managedCity, 0);