package jackall.moncalc.db import io.realm.RealmResults import jackall.moncalc.vo.Fruit /** * Created by matsumoto_k on 2017/11/02. */ class FruitRealmHelper : RealmHelper<Fruit>() { override fun insert(realmObject: Fruit) { realm.executeTransaction { realm.copyToRealmOrUpdate(realmObject) } } override fun insert(realmObject: List<Fruit>) { realm.executeTransaction { realm.copyToRealmOrUpdate(realmObject) } } override fun findAll(): RealmResults<Fruit> { return realm.where(Fruit::class.java).findAll() } }