Class Predicates
java.lang.Object
io.github.torand.fastersql.predicate.Predicates
Provides factory methods for predicates.
-
Method Summary
Modifier and TypeMethodDescriptionstatic ExistsSubqueryexists(ExpressionSubquery operand) Create an 'existence' (at least one row) predicate taking a subquery as right operand.static InSubqueryin(LeftOperand left, ExpressionSubquery right) Create a 'member of set' predicate taking a subquery as right operand.static Inin(LeftOperand left, Collection<?> right) Create a 'member of set' predicate taking a collection of scalar values as right operand.static IsNullisNull(LeftOperand operand) Creates an 'is null' predicate.static Likelike(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.
-