mirror of
https://github.com/querydsl/querydsl.git
synced 2026-06-13 21:01:01 +08:00
replaced BooleanExpression with Predicate
This commit is contained in:
parent
35a0657f0c
commit
95fc0ea6fb
@ -12,7 +12,7 @@ import com.mysema.query.QueryMetadata;
|
||||
import com.mysema.query.support.DetachableQuery;
|
||||
import com.mysema.query.types.EntityPath;
|
||||
import com.mysema.query.types.Path;
|
||||
import com.mysema.query.types.expr.BooleanExpression;
|
||||
import com.mysema.query.types.Predicate;
|
||||
import com.mysema.query.types.path.MapPath;
|
||||
|
||||
/**
|
||||
@ -137,7 +137,7 @@ public class AbstractJPQLSubQuery<Q extends AbstractJPQLSubQuery<Q>> extends Det
|
||||
return queryMixin.leftJoin(target, alias);
|
||||
}
|
||||
|
||||
public Q with(BooleanExpression... conditions){
|
||||
public Q with(Predicate... conditions){
|
||||
return queryMixin.with(conditions);
|
||||
}
|
||||
|
||||
|
||||
@ -5,7 +5,7 @@ import java.util.Collection;
|
||||
import com.mysema.query.Query;
|
||||
import com.mysema.query.types.EntityPath;
|
||||
import com.mysema.query.types.Path;
|
||||
import com.mysema.query.types.expr.BooleanExpression;
|
||||
import com.mysema.query.types.Predicate;
|
||||
import com.mysema.query.types.path.MapPath;
|
||||
|
||||
/**
|
||||
@ -271,6 +271,6 @@ public interface JPQLCommonQuery<Q extends JPQLCommonQuery<Q>> extends Query<Q>
|
||||
* @param condition
|
||||
* @return
|
||||
*/
|
||||
Q with(BooleanExpression... condition);
|
||||
Q with(Predicate... condition);
|
||||
|
||||
}
|
||||
|
||||
@ -12,7 +12,7 @@ import com.mysema.query.QueryMetadata;
|
||||
import com.mysema.query.support.ProjectableQuery;
|
||||
import com.mysema.query.types.EntityPath;
|
||||
import com.mysema.query.types.Path;
|
||||
import com.mysema.query.types.expr.BooleanExpression;
|
||||
import com.mysema.query.types.Predicate;
|
||||
import com.mysema.query.types.path.MapPath;
|
||||
|
||||
/**
|
||||
@ -171,7 +171,7 @@ public abstract class JPQLQueryBase<Q extends JPQLQueryBase<Q>> extends Projecta
|
||||
return queryMixin.leftJoin(target, alias);
|
||||
}
|
||||
|
||||
public Q with(BooleanExpression... conditions){
|
||||
public Q with(Predicate... conditions){
|
||||
return queryMixin.with(conditions);
|
||||
}
|
||||
|
||||
|
||||
@ -11,7 +11,7 @@ import com.mysema.query.JoinExpression;
|
||||
import com.mysema.query.JoinFlag;
|
||||
import com.mysema.query.QueryMetadata;
|
||||
import com.mysema.query.support.QueryMixin;
|
||||
import com.mysema.query.types.expr.BooleanExpression;
|
||||
import com.mysema.query.types.Predicate;
|
||||
|
||||
/**
|
||||
* JPQLQueryMixin extends QueryMixin to support JPQL join construction
|
||||
@ -48,8 +48,8 @@ public class JPQLQueryMixin<T> extends QueryMixin<T> {
|
||||
return getSelf();
|
||||
}
|
||||
|
||||
public T with(BooleanExpression... conditions){
|
||||
for (BooleanExpression condition : conditions){
|
||||
public T with(Predicate... conditions){
|
||||
for (Predicate condition : conditions){
|
||||
getMetadata().addJoinCondition(condition);
|
||||
}
|
||||
return getSelf();
|
||||
|
||||
@ -15,7 +15,7 @@ import com.mysema.query.sql.Configuration;
|
||||
import com.mysema.query.sql.OracleTemplates;
|
||||
import com.mysema.query.sql.SQLTemplates;
|
||||
import com.mysema.query.types.Expression;
|
||||
import com.mysema.query.types.expr.BooleanExpression;
|
||||
import com.mysema.query.types.Predicate;
|
||||
|
||||
/**
|
||||
* OracleQuery provides Oracle specific extensions to the base SQL query type
|
||||
@ -47,19 +47,19 @@ public class OracleQuery extends AbstractSQLQuery<OracleQuery> {
|
||||
super(conn, new Configuration(templates), metadata);
|
||||
}
|
||||
|
||||
public OracleQuery connectByPrior(BooleanExpression cond) {
|
||||
public OracleQuery connectByPrior(Predicate cond) {
|
||||
return addFlag(Position.BEFORE_ORDER, CONNECT_BY_PRIOR, cond);
|
||||
}
|
||||
|
||||
public OracleQuery connectBy(BooleanExpression cond) {
|
||||
public OracleQuery connectBy(Predicate cond) {
|
||||
return addFlag(Position.BEFORE_ORDER, CONNECT_BY, cond);
|
||||
}
|
||||
|
||||
public OracleQuery connectByNocyclePrior(BooleanExpression cond) {
|
||||
public OracleQuery connectByNocyclePrior(Predicate cond) {
|
||||
return addFlag(Position.BEFORE_ORDER, CONNECT_BY_NOCYCLE_PRIOR, cond);
|
||||
}
|
||||
|
||||
public <A> OracleQuery startWith(BooleanExpression cond) {
|
||||
public <A> OracleQuery startWith(Predicate cond) {
|
||||
return addFlag(Position.BEFORE_ORDER, START_WITH, cond);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user