本文整理了Java中com.psddev.dari.db.Query.setResolveInvisible
方法的一些代码示例,展示了Query.setResolveInvisible
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Query.setResolveInvisible
方法的具体详情如下:
包路径:com.psddev.dari.db.Query
类名称:Query
方法名:setResolveInvisible
[英]Sets whether this query will return objects with invisible references resolved.
[中]
代码示例来源:origin: perfectsense/dari
/**
* Sets this query to return objects with invisible
* references resolved.
*
* @see State#isResolveInvisible()
*/
public Query<E> resolveInvisible() {
setResolveInvisible(true);
return this;
}
代码示例来源:origin: perfectsense/brightspot-cms
@Override
public <T> List<T> readAll(Query<T> query) {
query.setResolveInvisible(true);
List<T> all = super.readAll(query);
for (T item : all) {
applyChanges(item);
}
return all;
}
代码示例来源:origin: perfectsense/brightspot-cms
@Override
public <T> T readFirst(Query<T> query) {
query.setResolveInvisible(true);
return applyChanges(super.readFirst(query));
}
代码示例来源:origin: perfectsense/brightspot-cms
@Override
public <T> Iterable<T> readIterable(Query<T> query, int fetchSize) {
query.setResolveInvisible(true);
return new FilteringIterable<T>(super.readIterable(query, fetchSize));
}
代码示例来源:origin: perfectsense/brightspot-cms
@Override
public <T> PaginatedResult<T> readPartial(Query<T> query, long offset, int limit) {
query.setResolveInvisible(true);
PaginatedResult<T> result = super.readPartial(query, offset, limit);
for (T item : result.getItems()) {
applyChanges(item);
}
return result;
}
代码示例来源:origin: perfectsense/dari
@Override
public Query<E> clone() {
Query<E> clone = new Query<E>(group, objectClass);
clone.setPredicate(predicate);
clone.setSorters(sorters != null ? new ArrayList<Sorter>(sorters) : null);
clone.setFields(fields != null ? new ArrayList<String>(fields) : null);
clone.setDatabase(database);
clone.setResolveToReferenceOnly(isResolveToReferenceOnly);
clone.setCache(!noCache);
clone.setMaster(master);
clone.setResolveInvisible(resolveInvisible);
clone.setTimeout(timeout);
clone.setOptions(options != null ? new HashMap<String, Object>(options) : null);
return clone;
}
内容来源于网络,如有侵权,请联系作者删除!