本文整理了Java中com.querydsl.core.types.ExpressionUtils.anyOf()
方法的一些代码示例,展示了ExpressionUtils.anyOf()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ExpressionUtils.anyOf()
方法的具体详情如下:
包路径:com.querydsl.core.types.ExpressionUtils
类名称:ExpressionUtils
方法名:anyOf
[英]Create the union of the given arguments
[中]
代码示例来源:origin: querydsl/querydsl
/**
* Create a {@code this && any(predicates)} expression
*
* <p>Returns an intersection of this and the union of the given predicates</p>
*
* @param predicates union of predicates
* @return this && any(predicates)
*/
public BooleanExpression andAnyOf(Predicate... predicates) {
return and(ExpressionUtils.anyOf(predicates));
}
代码示例来源:origin: querydsl/querydsl
/**
* Create the intersection of this and the union of the given args
* {@code (this && (arg1 || arg2 ... || argN))}
*
* @param args union of predicates
* @return the current object
*/
public BooleanBuilder andAnyOf(Predicate... args) {
if (args.length > 0) {
and(ExpressionUtils.anyOf(args));
}
return this;
}
代码示例来源:origin: org.huiche/huiche-data
/**
* or
*
* @param predicate 条件
* @return 最终条件
*/
@Nullable
default Predicate or(@Nonnull Predicate... predicate) {
return ExpressionUtils.anyOf(predicate);
}
代码示例来源:origin: com.querydsl/querydsl-core
/**
* Create a {@code this && any(predicates)} expression
*
* <p>Returns an intersection of this and the union of the given predicates</p>
*
* @param predicates union of predicates
* @return this && any(predicates)
*/
public BooleanExpression andAnyOf(Predicate... predicates) {
return and(ExpressionUtils.anyOf(predicates));
}
代码示例来源:origin: com.querydsl/querydsl-core
/**
* Create the intersection of this and the union of the given args
* {@code (this && (arg1 || arg2 ... || argN))}
*
* @param args union of predicates
* @return the current object
*/
public BooleanBuilder andAnyOf(Predicate... args) {
if (args.length > 0) {
and(ExpressionUtils.anyOf(args));
}
return this;
}
代码示例来源:origin: com.holon-platform.jpa/holon-datastore-jpa-querydsl
@Override
public PredicateExpression visit(OrFilter filter, QueryDslResolutionContext context) {
return PredicateExpression.create(ExpressionUtils.anyOf(resolveFilterList(filter.getComposition(), context)));
}
代码示例来源:origin: com.querydsl/querydsl-sql
@Test
public void or_in() {
StringPath path = Expressions.stringPath("str");
Expression<?> expr = ExpressionUtils.anyOf(
ExpressionUtils.in(path, Arrays.asList("1", "2", "3")),
ExpressionUtils.in(path, Arrays.asList("4", "5", "6")));
SQLSerializer serializer = new SQLSerializer(Configuration.DEFAULT);
serializer.handle(expr);
assertEquals(Arrays.asList(path, path, path, path, path, path), serializer.getConstantPaths());
assertEquals(6, serializer.getConstants().size());
}
内容来源于网络,如有侵权,请联系作者删除!