本文整理汇总了Java中com.querydsl.core.types.dsl.ListPath类的典型用法代码示例。如果您正苦于以下问题:Java ListPath类的具体用法?Java ListPath怎么用?Java ListPath使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ListPath类属于com.querydsl.core.types.dsl包,在下文中一共展示了ListPath类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: buildAppUserListQuery
import com.querydsl.core.types.dsl.ListPath; //导入依赖的package包/类
private Predicate buildAppUserListQuery(StringListQuery query, ListPath<AppUser, QAppUser> list) {
if (query.isEmpty()) {
return null;
}
BooleanBuilder predicate = new BooleanBuilder();
if (query.getIn() != null) {
predicate.and(list.any().id.in(query.getIn()));
}
return predicate;
}
示例2: buildListQuery
import com.querydsl.core.types.dsl.ListPath; //导入依赖的package包/类
private Predicate buildListQuery(StringListQuery query, ListPath<String, StringPath> list) {
if (query.isEmpty()) {
return null;
}
BooleanBuilder predicate = new BooleanBuilder();
if (query.getIn() != null && query.getIn().isEmpty()) {
predicate.and(list.any().in(query.getIn()));
}
return predicate;
}
示例3: findForeignHolder
import com.querydsl.core.types.dsl.ListPath; //导入依赖的package包/类
public <T extends CatalogItem, P extends CatalogItem> List<P> findForeignHolder(EntityPath<P> hp,
ListPath<T, ? extends SimpleExpression<T>> h, T c) {
return new JPAQueryFactory(entityManager)
.selectFrom(hp)
.where(h.contains(c))
.fetch();
}
示例4: validateLeftJoin
import com.querydsl.core.types.dsl.ListPath; //导入依赖的package包/类
/**
* Checks if there is already existing join. Useful if there is no need for
* duplicate joins.
*
* @param <P>
* entity type parameter
* @param <Z>
* path type parameter
* @param target
* entity field as a target
* @param alias
* alias name for join created
* @return alias used in join
*/
protected <P, Z extends EntityPathBase<P>> Z validateLeftJoin(ListPath<P, Z> target, Z alias) {
if (!joins.contains(alias)) {
getQuery().leftJoin(target, alias);
joins.add(alias);
}
return alias;
}
示例5: validateJoin
import com.querydsl.core.types.dsl.ListPath; //导入依赖的package包/类
/**
* Checks if there is already existing join. Useful if there is no need for
* duplicate joins.
*
* @param <P>
* entity type parameter
* @param <Z>
* path type parameter
* @param target
* entity field as a target
* @param alias
* alias name for join created
* @return alias used in join
*/
protected <P, Z extends EntityPathBase<P>> Z validateJoin(ListPath<P, Z> target, Z alias) {
if (!joins.contains(alias)) {
getQuery().join(target, alias);
joins.add(alias);
}
return alias;
}