接口 StringExpression
- 所有超级接口:
ComparableExpression<String>,Expression<String>,Selection<String>
- 所有已知子接口:
PropExpression.Str
-
嵌套类概要
从接口继承的嵌套类/接口 org.babyfish.jimmer.sql.ast.Expression
Expression.AnyFactory, Expression.ComparableFactory, Expression.NumericFactory, Expression.StringFactory -
方法概要
修饰符和类型方法说明@NotNull StringExpression@NotNull StringExpressioncoalesce(Expression<String> defaultExpr) @NotNull StringExpressionconcat(Expression<String>... others) default @NotNull PredicateReturns a case-insensitive like predicate for the given pattern with default match mode.@NotNull PredicateReturns a case-insensitive LIKE predicate with the given pattern and match mode.default @Nullable PredicateCreate `case-insensitive like` expression when the argument `condition` is true and the argument `pattern` is neither null nor empty string.default @Nullable PredicateCreate `insensitively like` expression when the argument `condition` is true and the argument `pattern` is neither null nor empty string.default @Nullable PredicateCreate `case-insensitive like` expression when the argument `pattern` is neither null nor empty string.default @Nullable PredicateCreate `insensitively like` expression when the argument `pattern` is neither null nor empty string.default @NotNull PredicateReturns a LIKE predicate for the given pattern with default match mode.@NotNull PredicateReturns a LIKE predicate with the given pattern and match mode.default @Nullable PredicateReturns a LIKE predicate if the given condition is true and pattern is not null or empty.default @Nullable PredicateCreate `like` expression when the argument `condition` is true and the argument `pattern` is neither null nor empty string.default @Nullable PredicateReturns a LIKE predicate if the given pattern is not null or empty.default @Nullable PredicateCreate `like` expression when the argument `pattern` is neither null nor empty string.lower()upper()从接口继承的方法 org.babyfish.jimmer.sql.ast.ComparableExpression
between, between, betweenIf, betweenIf, ge, ge, geIf, geIf, gt, gt, gtIf, gtIf, le, le, leIf, leIf, lt, lt, ltIf, ltIf, notBetween, notBetween, notBetweenIf, notBetweenIf
-
方法详细资料
-
like
Returns a LIKE predicate for the given pattern with default match mode.The pattern must not be null. The default match mode used is
LikeMode.ANYWHERE, which matches the pattern anywhere in the value.- 参数:
pattern- the pattern to match, must not be null- 返回:
- the LIKE predicate
- 抛出:
NullPointerException- if the pattern is null
-
likeIf
Returns a LIKE predicate if the given condition is true and pattern is not null or empty. The LIKE predicate matches values that contain the given pattern anywhere in the value (LikeMode.ANYWHERE).- 参数:
condition- the condition to checkpattern- the pattern to match in the LIKE predicate, may be null- 返回:
- a LIKE predicate if the condition is true and pattern is not null or empty, null otherwise
-
likeIf
Returns a LIKE predicate if the given pattern is not null or empty. The LIKE predicate matches values that contain the given pattern anywhere in the value (LikeMode.ANYWHERE).This is an overload of the
likeIf(boolean, String)method that passes a condition of true.- 参数:
pattern- the pattern to match in the LIKE predicate, may be null- 返回:
- a LIKE predicate if the pattern is not null or empty, null otherwise
-
like
Returns a LIKE predicate with the given pattern and match mode.Neither the pattern nor match mode may be null.
- 参数:
pattern- the pattern to match, must not be nulllikeMode- the mode determining how to match the pattern, must not be null- 返回:
- the LIKE predicate
- 抛出:
NullPointerException- if pattern or likeMode is null
-
likeIf
@Nullable default @Nullable Predicate likeIf(boolean condition, @Nullable @Nullable String pattern, LikeMode likeMode) Create `like` expression when the argument `condition` is true and the argument `pattern` is neither null nor empty string.- 参数:
condition- The condition, if it is false, returns null directly, otherwise check the other parameter `pattern`pattern- The pattern, If it is null or empty string, returns null directly, otherwise check the other parameter `condition`likeMode- The like mode which can beLikeMode.ANYWHERE,LikeMode.START,LikeMode.ENDorLikeMode.EXACT- 返回:
- The `like` expression or null
-
likeIf
Create `like` expression when the argument `pattern` is neither null nor empty string.- 参数:
pattern- The pattern, If it is null or empty string, returns null directly, otherwise check create the expressionlikeMode- The like mode which can beLikeMode.ANYWHERE,LikeMode.START,LikeMode.ENDorLikeMode.EXACT- 返回:
- The `like` expression or null
-
ilike
Returns a case-insensitive like predicate for the given pattern with default match mode.The pattern must not be null. The default match mode used is
LikeMode.ANYWHERE, which matches the pattern anywhere in the value.- 参数:
pattern- the pattern to match, must not be null- 返回:
- the case-insensitive LIKE predicate
- 抛出:
NullPointerException- if the pattern is null
-
ilikeIf
@Nullable default @Nullable Predicate ilikeIf(boolean condition, @Nullable @Nullable String pattern) Create `case-insensitive like` expression when the argument `condition` is true and the argument `pattern` is neither null nor empty string.- 参数:
condition- The condition, if it is false, returns null directly, otherwise check the other parameter `pattern`pattern- The pattern, If it is null or empty string, returns null directly, otherwise check the other parameter `condition`- 返回:
- The `insensitively like` expression or null
-
ilikeIf
Create `case-insensitive like` expression when the argument `pattern` is neither null nor empty string.- 参数:
pattern- The pattern, If it is null or empty string, returns null directly, otherwise check create the expression- 返回:
- The `insensitively like` expression or null
-
ilike
Returns a case-insensitive LIKE predicate with the given pattern and match mode.Neither the pattern nor like mode may be null, otherwise
NullPointerExceptionwill be thrown.- 参数:
pattern- the pattern to match in the LIKE predicate, must not be nulllikeMode- the mode determining how to match the pattern, must not be null- 返回:
- the case-insensitive LIKE predicate
- 抛出:
NullPointerException- ifpatternorlikeModeis null
-
ilikeIf
@Nullable default @Nullable Predicate ilikeIf(boolean condition, @Nullable @Nullable String pattern, LikeMode likeMode) Create `insensitively like` expression when the argument `condition` is true and the argument `pattern` is neither null nor empty string.- 参数:
condition- The condition, if it is false, returns null directly, otherwise check the other parameter `pattern`pattern- The pattern, If it is null or empty string, returns null directly, otherwise check the other parameter `condition`likeMode- The like mode which can beLikeMode.ANYWHERE,LikeMode.START,LikeMode.ENDorLikeMode.EXACT- 返回:
- The `insensitively like` expression or null
-
ilikeIf
@Nullable default @Nullable Predicate ilikeIf(@Nullable @Nullable String pattern, LikeMode likeMode) Create `insensitively like` expression when the argument `pattern` is neither null nor empty string.- 参数:
pattern- The pattern, If it is null or empty string, returns null directly, otherwise check create the expressionlikeMode- The like mode which can beLikeMode.ANYWHERE,LikeMode.START,LikeMode.ENDorLikeMode.EXACT- 返回:
- The `insensitively like` expression or null
-
upper
StringExpression upper() -
lower
StringExpression lower() -
concat
-
concat
-
coalesce
- 指定者:
coalesce在接口中ComparableExpression<String>- 指定者:
coalesce在接口中Expression<String>
-
coalesce
- 指定者:
coalesce在接口中ComparableExpression<String>- 指定者:
coalesce在接口中Expression<String>
-
coalesceBuilder
- 指定者:
coalesceBuilder在接口中ComparableExpression<String>- 指定者:
coalesceBuilder在接口中Expression<String>
-