简体   繁体   中英

Java Android Realm contains

I want to get a result with contains with world I do this ;

  public static RealmResults<WyborTrasyRealm> getFiltrWyborTrasyLists(Realm realm,String column, String filtr) {
        return realm.where(WyborTrasyRealm.class).contains(column,filtr).findAll();
    }

But when I have a row with name : TAG and when I in constains have

realm.where(WyborTrasyRealm.class).contains(name,"tag").findAll();

I get an empty list how I can ignore case in realm ?

I do this and it works :

 public static RealmResults<WyborTrasyRealm> getFiltrWyborTrasyLists(Realm realm,String column, String filtr) {
        return realm.where(WyborTrasyRealm.class).contains(column,filtr,  Case.INSENSITIVE).findAll();
    }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM