Class Predicates
java.lang.Object
io.github.torand.fastersql.predicate.Predicates
Provides factory methods for predicates.
-
Method Summary
Modifier and TypeMethodDescriptionstatic ExistsSubquery
exists
(ExpressionSubquery operand) Create an 'existence' (at least one row) predicate taking a subquery as right operand.static InSubquery
in
(LeftOperand left, ExpressionSubquery right) Create a 'member of set' predicate taking a subquery as right operand.static In
in
(LeftOperand left, Collection<?> right) Create a 'member of set' predicate taking a collection of scalar values as right operand.static IsNull
isNull
(LeftOperand operand) Creates an 'is null' predicate.static Like
like
(LeftOperand left, String right) Creates a pattern matching predicate.
-
Method Details
-
in
Create a 'member of set' predicate taking a collection of scalar values as right operand.- Parameters:
left
- the left operand.right
- the right operand (scalar value collection).- Returns:
- the predicate.
-
in
Create a 'member of set' predicate taking a subquery as right operand.- Parameters:
left
- the left operand.right
- the right operand (subquery).- Returns:
- the predicate.
-
exists
Create an 'existence' (at least one row) predicate taking a subquery as right operand.- Parameters:
operand
- the operand (subquery).- Returns:
- the predicate.
-
like
Creates a pattern matching predicate.- Parameters:
left
- the left operand.right
- the right operand (pattern).- Returns:
- the predicate.
-
isNull
Creates an 'is null' predicate.- Parameters:
operand
- the operand.- Returns:
- the predicate.
-