本文整理了Java中org.greenrobot.greendao.Property.notIn()
方法的一些代码示例,展示了Property.notIn()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Property.notIn()
方法的具体详情如下:
包路径:org.greenrobot.greendao.Property
类名称:Property
方法名:notIn
[英]Creates an "NOT IN (..., ..., ...)" condition for this property.
[中]创建一个“不在(…,…,…)”这处房产的条件。
代码示例来源:origin: greenrobot/greenDAO
/** Creates an "NOT IN (..., ..., ...)" condition for this property. */
public WhereCondition notIn(Collection<?> notInValues) {
return notIn(notInValues.toArray());
}
代码示例来源:origin: greenrobot/greenDAO
public void testNotIn() {
ArrayList<TestEntity> inserted = insert(5);
String value1 = getSimpleString(0);
String value2 = getSimpleString(2);
String value3 = getSimpleString(4);
List<TestEntity> result = dao.queryBuilder().where(Properties.SimpleString.notIn(value1, value2, value3))
.orderAsc(Properties.SimpleString).list();
assertEquals(2, result.size());
TestEntity resultEntity1 = result.get(0);
assertEquals(inserted.get(1).getId(), resultEntity1.getId());
TestEntity resultEntity2 = result.get(1);
assertEquals(inserted.get(3).getId(), resultEntity2.getId());
}
代码示例来源:origin: Rukey7/MvpApp
@Override
public void getData(boolean isRefresh) {
mView.updateLovedCount((int) mDbDao.queryBuilder().where(VideoInfoDao.Properties.IsCollect.eq(true)).count());
mView.updateDownloadCount((int) mDbDao.queryBuilder()
.where(VideoInfoDao.Properties.DownloadStatus.notIn(DownloadStatus.NORMAL, DownloadStatus.COMPLETE)).count());
}
代码示例来源:origin: greenrobot/greenDAO
public void testWhereWithSpecialNamesWithValues() {
QueryBuilder<SpecialNamesEntity> queryBuilder = dao.queryBuilder();
queryBuilder.where(Properties.Avg.eq("test"));
queryBuilder.where(Properties.Count.notIn("test", "test2"));
queryBuilder.where(Properties.Distinct.ge("test"));
queryBuilder.where(Properties.Index.le("test"));
queryBuilder.where(Properties.Join.like("test"));
queryBuilder.where(Properties.On.notEq("test"));
queryBuilder.where(Properties.Select.in("test", "test2"));
queryBuilder.where(Properties.Sum.lt(1));
queryBuilder.where(Properties.Order.gt(1));
queryBuilder.list();
queryBuilder.buildCount().count();
queryBuilder.buildDelete().executeDeleteWithoutDetachingEntities();
}
代码示例来源:origin: org.greenrobot/greendao
/** Creates an "NOT IN (..., ..., ...)" condition for this property. */
public WhereCondition notIn(Collection<?> notInValues) {
return notIn(notInValues.toArray());
}
内容来源于网络,如有侵权,请联系作者删除!