public interface QueryCondition
Modifier and Type | Method and Description |
---|---|
QueryCondition |
and()
Create a condition group and.
|
<C,T extends C> |
between(C target,
T from,
T to)
Add an between condition with a target and a range( from to ).
|
<C,T extends C> |
contains(Collection<C> target,
SelectQuery<T> value)
Add a contains condition between expression and a query.
|
<C,T extends C> |
contains(Collection<C> target,
T value)
Add a contains condition between two values.
|
<C,T extends C> |
eq(C target,
SelectQuery<T> value)
Add an equal condition between expression and a query.
|
<C,T extends C> |
eq(C target,
T value)
Add an equal condition between two values.
|
<C,T extends C> |
gt(C target,
SelectQuery<T> value)
Add a "grater than" condition between expression and a query.
|
<C,T extends C> |
gt(C target,
T value)
Add a "grater than" condition between two values.
|
<C,T extends C> |
gtEq(C target,
SelectQuery<T> value)
Add an "grater than or equals" condition between expression and a query.
|
<C,T extends C> |
gtEq(C target,
T value)
Add a "grater than or equals" condition between two values.
|
<C,T extends C> |
in(C target,
SelectQuery<T> value)
Add an in condition between expression and a query.
|
<C,T extends Collection<? extends C>> |
in(C target,
T value)
Add an in condition between two values.
|
<C,T extends C> |
like(C target,
T value)
Add a like condition between two values.
|
<C,T extends C> |
likeNc(C target,
T value)
Add a like condition between two values without case match.
|
<C,T extends C> |
lt(C target,
SelectQuery<T> value)
Add a "lesser than" condition between expression and a query.
|
<C,T extends C> |
lt(C target,
T value)
Add a "lesser than" condition between two values.
|
<C,T extends C> |
ltEq(C target,
SelectQuery<T> value)
Add a min or equals condition between expression and a query.
|
<C,T extends C> |
ltEq(C target,
T value)
Add a "lesser than" or equals condition between two values.
|
<C,T extends C> |
notContains(Collection<C> target,
SelectQuery<T> value)
Add a not contains condition between expression and a query.
|
<C,T extends C> |
notContains(Collection<C> target,
T value)
Add a not contains condition between two values.
|
<C,T extends C> |
notEq(C target,
SelectQuery<T> value)
Add a not equal condition between expression and a query.
|
<C,T extends C> |
notEq(C target,
T value)
Add a not equal condition between two values.
|
<C,T extends C> |
notIn(C target,
SelectQuery<T> value)
Add a not in condition between expression and a query.
|
<C,T extends Collection<? extends C>> |
notIn(C target,
T value)
Add a not in condition between two values.
|
<C,T extends C> |
notLike(C target,
T value)
Add a not like condition between two values.
|
<C,T extends C> |
notLikeNc(C target,
T value)
Add a not like condition between two values without case match.
|
QueryCondition |
or()
Create a condition group or.
|
<C,T extends C> void eq(C target, T value)
query.eq(query.target().getName(),"example");
target
- the base operation target.value
- the operation expected value.<C,T extends C> void eq(C target, SelectQuery<T> value)
SelectQuery<Person> anotherQuery = ...
query.eq(query.target().getMum(),anoterQuery);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void notEq(C target, T value)
query.notEq(query.target().getName(),"example");
target
- the base operation target.value
- the operation expected value.<C,T extends C> void notEq(C target, SelectQuery<T> value)
SelectQuery<Person> anotherQuery = ...
query.notEq(query.target().getMum(),anoterQuery);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void gt(C target, T value)
query.gt(query.target().getHeight(),30);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void gt(C target, SelectQuery<T> value)
SelectQuery<Person> anotherQuery = ...
query.gt(query.target().getMembers(),anoterQuery);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void gtEq(C target, T value)
query.gtEq(query.target().getHeight(),30);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void gtEq(C target, SelectQuery<T> value)
SelectQuery<Person> anotherQuery = ...
query.gtEq(query.target().getMembers(),anoterQuery);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void lt(C target, T value)
query.lt(query.target().getHeight(),30);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void lt(C target, SelectQuery<T> value)
SelectQuery<Person> anotherQuery = ...
query.lt(query.target().getMembers(),anoterQuery);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void ltEq(C target, T value)
query.ltEq(query.target().getHeight(),30);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void ltEq(C target, SelectQuery<T> value)
SelectQuery<Person> anotherQuery = ...
query.ltEq(query.target().getMembers(),anoterQuery);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void like(C target, T value)
query.like(query.target().getName(),"lk");
target
- the base operation target.value
- the operation expected value.<C,T extends C> void notLike(C target, T value)
query.notLike(query.target().getName(),"lk");
target
- the base operation target.value
- the operation expected value.<C,T extends Collection<? extends C>> void in(C target, T value)
Collection inValues = ...
query.in(query.target().getName(), inValues);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void in(C target, SelectQuery<T> value)
SelectQuery<Person> inValues = ...
query.in(query.target().getMum(), inValues);
target
- the base operation target.value
- the query source of expected value.<C,T extends Collection<? extends C>> void notIn(C target, T value)
Collection inValues = ...
query.in(query.target().getName(), inValues);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void notIn(C target, SelectQuery<T> value)
SelectQuery<Person> inValues = ...
query.notIn(query.target().getMum(), inValues);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void contains(Collection<C> target, T value)
Person contained = ...
query.contains(query.target().getFriends(), contained);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void contains(Collection<C> target, SelectQuery<T> value)
SelectQuery<Person> contained = ...
query.contains(query.target().getFriends(), contained);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void notContains(Collection<C> target, T value)
Person notContained = ...
query.notContains(query.target().getFriends(), contained);
target
- the base operation target.value
- the operation expected value.<C,T extends C> void notContains(Collection<C> target, SelectQuery<T> value)
SelectQuery<Person> notContained = ...
query.notContains(query.target().getFriends(), notContained);
target
- the base operation target.value
- the query source of expected value.<C,T extends C> void likeNc(C target, T value)
query.likeNc(query.target().getName(), "NoCaseTest");
target
- the base operation target.value
- the operation expected value.<C,T extends C> void notLikeNc(C target, T value)
query.notLikeNc(query.target().getName(), "NoCaseTest");
target
- the base operation target.value
- the operation expected value.<C,T extends C> void between(C target, T from, T to)
query.between(query.target().getSize(), 5, 10);
target
- the target of between operation.from
- the value from.to
- the value to.QueryCondition or()
QueryCondition or = query.or();
or.eq(....
QueryCondition and()
QueryCondition and = query.and();
and.eq(....
Copyright © 2014 Object Query. All rights reserved.