mirror of
https://github.com/querydsl/querydsl.git
synced 2026-06-24 21:07:26 +08:00
fixed compilation errors
This commit is contained in:
parent
deb2fe7502
commit
2cfe17028b
@ -12,6 +12,7 @@
|
||||
|
||||
<groupId>com.mysema.querydsl</groupId>
|
||||
<artifactId>querydsl-core</artifactId>
|
||||
<name>querydsl core</name>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<dependencies>
|
||||
|
||||
@ -8,6 +8,8 @@ package com.mysema.query;
|
||||
import com.mysema.query.grammar.OrderSpecifier;
|
||||
import com.mysema.query.grammar.types.Expr;
|
||||
|
||||
import static com.mysema.query.grammar.types.Expr.*;
|
||||
|
||||
/**
|
||||
* Query provides a the query interface of the fluent query DSL
|
||||
*
|
||||
@ -16,11 +18,11 @@ import com.mysema.query.grammar.types.Expr;
|
||||
*/
|
||||
public interface Query<A extends Query<A>>{
|
||||
A select(Expr<?>... o);
|
||||
A from(Expr.Entity<?>... o);
|
||||
@Deprecated A innerJoin(Expr.Entity<?> o);
|
||||
@Deprecated A join(Expr.Entity<?> o);
|
||||
@Deprecated A fullJoin(Expr.Entity<?> o);
|
||||
@Deprecated A leftJoin(Expr.Entity<?> o);
|
||||
A from(Entity<?>... o);
|
||||
@Deprecated A innerJoin(Entity<?> o);
|
||||
@Deprecated A join(Entity<?> o);
|
||||
@Deprecated A fullJoin(Entity<?> o);
|
||||
@Deprecated A leftJoin(Entity<?> o);
|
||||
@Deprecated A with(Expr.Boolean... o);
|
||||
A where(Expr.Boolean... o);
|
||||
A groupBy(Expr<?>... o);
|
||||
|
||||
@ -11,6 +11,8 @@ import java.util.List;
|
||||
|
||||
import com.mysema.query.grammar.OrderSpecifier;
|
||||
import com.mysema.query.grammar.types.Expr;
|
||||
import static com.mysema.query.grammar.types.Expr.*;
|
||||
|
||||
/**
|
||||
* QueryBase provides a basic implementation of the Query interface
|
||||
*
|
||||
@ -38,8 +40,8 @@ public class QueryBase<A extends QueryBase<A>> implements Query<A> {
|
||||
|
||||
private final Metadata metadata = new Metadata();
|
||||
|
||||
public A from(Expr.Entity<?>... o) {
|
||||
for (Expr.Entity<?> expr : o){
|
||||
public A from(Entity<?>... o) {
|
||||
for (Entity<?> expr : o){
|
||||
joins.add(new JoinExpression(JoinType.DEFAULT,expr));
|
||||
}
|
||||
return (A) this;
|
||||
@ -55,22 +57,22 @@ public class QueryBase<A extends QueryBase<A>> implements Query<A> {
|
||||
return (A) this;
|
||||
}
|
||||
|
||||
public A innerJoin(Expr.Entity<?> o) {
|
||||
public A innerJoin(Entity<?> o) {
|
||||
joins.add(new JoinExpression(JoinType.INNERJOIN,o));
|
||||
return (A) this;
|
||||
}
|
||||
|
||||
public A fullJoin(Expr.Entity<?> o) {
|
||||
public A fullJoin(Entity<?> o) {
|
||||
joins.add(new JoinExpression(JoinType.FULLJOIN,o));
|
||||
return (A) this;
|
||||
}
|
||||
|
||||
public A join(Expr.Entity<?> o) {
|
||||
public A join(Entity<?> o) {
|
||||
joins.add(new JoinExpression(JoinType.JOIN,o));
|
||||
return (A) this;
|
||||
}
|
||||
|
||||
public A leftJoin(Expr.Entity<?> o) {
|
||||
public A leftJoin(Entity<?> o) {
|
||||
joins.add(new JoinExpression(JoinType.LEFTJOIN,o));
|
||||
return (A) this;
|
||||
}
|
||||
|
||||
@ -15,16 +15,16 @@ import com.mysema.query.grammar.Ops.Op;
|
||||
*/
|
||||
public class Factory {
|
||||
|
||||
public static void checkArg(String name, Object obj) {
|
||||
if (obj == null) throw new IllegalArgumentException(name + " was null");
|
||||
}
|
||||
|
||||
public static final Expr.Boolean createBoolean(Op<Boolean> operator, Expr<?>... args) {
|
||||
checkArg("operator",operator);
|
||||
checkArg("args",args);
|
||||
return new Operation.Boolean(operator, args);
|
||||
}
|
||||
|
||||
public static void checkArg(String name, Object obj) {
|
||||
if (obj == null) throw new IllegalArgumentException(name + " was null");
|
||||
}
|
||||
|
||||
public static final <OP, RT extends Comparable<RT>> Expr.Comparable<RT> createComparable(Op<OP> operator, Expr<?>... args) {
|
||||
checkArg("operator",operator);
|
||||
checkArg("args",args);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user