Interface IScalarExpressionStateObjectBuilder<T extends IScalarExpressionStateObjectBuilder<T>>
-
- All Known Subinterfaces:
IAbstractConditionalExpressionStateObjectBuilder<T>,ICaseExpressionStateObjectBuilder,IConditionalExpressionStateObjectBuilder,IEclipseLinkConditionalStateObjectBuilder,IEclipseLinkSelectExpressionStateObjectBuilder,IEclipseLinkSimpleSelectExpressionStateObjectBuilder,INewValueStateObjectBuilder,ISelectExpressionStateObjectBuilder,ISimpleSelectExpressionStateObjectBuilder
- All Known Implementing Classes:
AbstractCaseExpressionStateObjectBuilder,AbstractConditionalExpressionStateObjectBuilder,AbstractConditionalStateObjectBuilderWrapper,AbstractEclipseLinkSelectExpressionStateObjectBuilder,AbstractEclipseLinkSimpleSelectExpressionStateObjectBuilder,AbstractNewValueStateObjectBuilder,AbstractScalarExpressionStateObjectBuilder,AbstractSelectExpressionStateObjectBuilder,AbstractSimpleSelectExpressionStateObjectBuilder,DefaultCaseExpressionStateObjectBuilder,DefaultConditionalExpressionStateObjectBuilder,DefaultNewValueStateObjectBuilder,DefaultSelectExpressionStateObjectBuilder,DefaultSimpleSelectExpressionStateObjectBuilder,EclipseLinkConditionalStateObjectBuilder,EclipseLinkSelectExpressionStateObjectBuilder,EclipseLinkSimpleSelectExpressionStateObjectBuilder
public interface IScalarExpressionStateObjectBuilder<T extends IScalarExpressionStateObjectBuilder<T>>This builder can be used to easily create a scalar expression without having to create each object manually.- Version:
- 2.4
- Author:
- Pascal Filion
- Since:
- 2.4
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Tabs(T builder)Creates the expressionABS(x).Tadd(T builder)Creates the expressionx + y.Tavg(java.lang.String path)Creates the expressionAVG(path).TavgDistinct(java.lang.String path)Creates the expressionAVG(DISTINCT path).Tcase_(ICaseExpressionStateObjectBuilder builder)Creates a newCASEexpression.Tcoalesce(T builder1, T builder2, T... builders)Create the expressionCOALESCE(scalar_expression {, scalar_expression}+).Tconcat(T builder1, T builder2, T... builders)Creates the expressionCONCAT(string_primary, string_primary {, string_primary}*).Tcount(java.lang.String path)Creates the expressionCOUNT(identification_variable | state_field_path_expression | single_valued_object_path_expression).TcountDistinct(java.lang.String path)Creates the expressionCOUNT(DISTINCT identification_variable | state_field_path_expression | single_valued_object_path_expression).TcurrentDate()Creates the expression representingCURRENT_DATE.TcurrentTime()Creates the expression representingCURRENT_TIME.TcurrentTimestamp()Creates the expression representingCURRENT_TIMESTAMP.Tdate(java.lang.String jdbcDate)Creates a new date using the JDBC syntax of a date.Tdivide(T builder)Creates the expressionx / y.TentityType(java.lang.String entityTypeName)Creates a new entity type literal.TenumLiteral(java.lang.Enum<? extends java.lang.Enum<?>> enumConstant)Creates a new enum literal.Tfunction(java.lang.String identifier, java.lang.String functionName, java.lang.String... arguments)Creates the expression<identifier>('functionName' {, expression}*).Tfunction(java.lang.String identifier, java.lang.String functionName, T... arguments)Creates the expression<identifier>('functionName' {, expression}*).ICaseExpressionStateObjectBuildergetCaseBuilder()Returns the builder that can create aCASEexpression, which requires aIConditionalExpressionStateObjectBuilderto build theWHENclauses.Tindex(java.lang.String variable)Creates the expressionINDEX(identification_variable).Tlength(T builder)Creates the expressionLENGTH(expression).Tlocate(T parameter1, T parameter2)Creates the expressionLOCATE(string_primary, string_primary).Tlocate(T parameter1, T parameter2, T parameter3)Creates the expressionLOCATE(string_primary, string_primary [, simple_arithmetic_expression]).Tmax(java.lang.String path)Creates the expressionMAX(path).TmaxDistinct(java.lang.String path)Creates the expressionMAX(DISTINCT path).Tmin(java.lang.String path)Creates the expressionAVG(path).TminDistinct(java.lang.String path)Creates the expressionAVG(DISTINCT path).Tminus(T builder)Creates the expression- x.Tmod(T parameter1, T parameter2)Creates the expressionMOD(simple_arithmetic_expression, simple_arithmetic_expression).Tmultiply(T builder)Creates the expressionx * y.TnullIf(T builder1, T builder2)Create the expressionNULLIF(scalar_expression, scalar_expression).Tnumeric(java.lang.Number number)Creates the numeric literal.Tnumeric(java.lang.String number)Creates the numeric literal.Tparameter(java.lang.String parameter)Creates the input parameter.Tpath(java.lang.String path)Creates a new state field path expression.Tplus(T builder)Creates the expression+ x.Tsize(java.lang.String path)Creates the expressionSIZE(collection_valued_path_expression).Tsqrt(T builder)Creates the expressionSQRT(x).Tstring(java.lang.String literal)Creates a new string literal.Tsub(T builder)Creates an encapsulated expression:(expression).Tsubtract(T builder)Creates the expressionx - y.Tsum(java.lang.String path)Creates the expressionSUM(path).TsumDistinct(java.lang.String path)Creates the expressionSUM(path).Ttype(java.lang.String path)Creates the expressionTYPE(identification_variable | single_valued_object_path_expression | input_parameter).
-
-
-
Method Detail
-
abs
T abs(T builder)
Creates the expressionABS(x).- Parameters:
builder- The parameter of theABSexpression- Returns:
- This This builder
-
add
T add(T builder)
Creates the expressionx + y.- Parameters:
builder- The right side of the addition expression- Returns:
- This builder
-
avg
T avg(java.lang.String path)
Creates the expressionAVG(path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
avgDistinct
T avgDistinct(java.lang.String path)
Creates the expressionAVG(DISTINCT path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
case_
T case_(ICaseExpressionStateObjectBuilder builder)
Creates a newCASEexpression.- Parameters:
builder- Thebuilderof aCASEexpression- Returns:
- This This builder
-
coalesce
T coalesce(T builder1, T builder2, T... builders)
Create the expressionCOALESCE(scalar_expression {, scalar_expression}+).- Parameters:
builder1- The first scalar expressionbuilder2- The second scalar expressionbuilders- The subsequent scalar expressions- Returns:
- This This builder
-
concat
T concat(T builder1, T builder2, T... builders)
Creates the expressionCONCAT(string_primary, string_primary {, string_primary}*).- Parameters:
builder1- The first argument of the expressionbuilder2- The second argument of the expressionbuilders- The subsequence arguments of the expression, which are optional- Returns:
- This This builder
-
count
T count(java.lang.String path)
Creates the expressionCOUNT(identification_variable | state_field_path_expression | single_valued_object_path_expression).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
countDistinct
T countDistinct(java.lang.String path)
Creates the expressionCOUNT(DISTINCT identification_variable | state_field_path_expression | single_valued_object_path_expression).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
currentDate
T currentDate()
Creates the expression representingCURRENT_DATE.- Returns:
- This This builder
-
currentTime
T currentTime()
Creates the expression representingCURRENT_TIME.- Returns:
- This This builder
-
currentTimestamp
T currentTimestamp()
Creates the expression representingCURRENT_TIMESTAMP.- Returns:
- This This builder
-
date
T date(java.lang.String jdbcDate)
Creates a new date using the JDBC syntax of a date.- Returns:
- This This builder
-
divide
T divide(T builder)
Creates the expressionx / y.- Parameters:
builder- The right side of the division expression- Returns:
- This This builder
-
entityType
T entityType(java.lang.String entityTypeName)
Creates a new entity type literal.- Parameters:
entityTypeName- The short name of the entity- Returns:
- This This builder
-
enumLiteral
T enumLiteral(java.lang.Enum<? extends java.lang.Enum<?>> enumConstant)
Creates a new enum literal.- Parameters:
enumConstant- The enum constant- Returns:
- This This builder
-
function
T function(java.lang.String identifier, java.lang.String functionName, java.lang.String... arguments)
Creates the expression<identifier>('functionName' {, expression}*).- Parameters:
identifier- The JPQL identifier that is used to identify the SQL expressionfunctionName- The name of the native SQL functionarguments- The arguments of the expression- Returns:
- This builder
-
function
T function(java.lang.String identifier, java.lang.String functionName, T... arguments)
Creates the expression<identifier>('functionName' {, expression}*).- Parameters:
identifier- The JPQL identifier that is used to identify the SQL expressionfunctionName- The name of the native SQL functionarguments- The arguments of the expression- Returns:
- This builder
-
getCaseBuilder
ICaseExpressionStateObjectBuilder getCaseBuilder()
Returns the builder that can create aCASEexpression, which requires aIConditionalExpressionStateObjectBuilderto build theWHENclauses.- Returns:
- The builder of a
CASEexpression
-
index
T index(java.lang.String variable)
Creates the expressionINDEX(identification_variable).- Parameters:
variable- The identification variable- Returns:
- This This builder
-
length
T length(T builder)
Creates the expressionLENGTH(expression).- Parameters:
builder- The encapsulated expression- Returns:
- This This builder
-
locate
T locate(T parameter1, T parameter2)
Creates the expressionLOCATE(string_primary, string_primary).- Parameters:
parameter1- The first string primaryparameter2- The second string primary- Returns:
- This This builder
-
locate
T locate(T parameter1, T parameter2, T parameter3)
Creates the expressionLOCATE(string_primary, string_primary [, simple_arithmetic_expression]).- Parameters:
parameter1- The first string primaryparameter2- The second string primaryparameter3- The position of the search within the string- Returns:
- This This builder
-
max
T max(java.lang.String path)
Creates the expressionMAX(path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
maxDistinct
T maxDistinct(java.lang.String path)
Creates the expressionMAX(DISTINCT path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
min
T min(java.lang.String path)
Creates the expressionAVG(path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
minDistinct
T minDistinct(java.lang.String path)
Creates the expressionAVG(DISTINCT path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
minus
T minus(T builder)
Creates the expression- x.- Parameters:
builder- The expression that will have the plus sign prepended- Returns:
- This This builder
-
mod
T mod(T parameter1, T parameter2)
Creates the expressionMOD(simple_arithmetic_expression, simple_arithmetic_expression).- Parameters:
parameter1- The first parameterparameter2- The second parameter- Returns:
- This This builder
-
multiply
T multiply(T builder)
Creates the expressionx * y.- Parameters:
builder- The right side of the multiply expression- Returns:
- This This builder
-
nullIf
T nullIf(T builder1, T builder2)
Create the expressionNULLIF(scalar_expression, scalar_expression).- Parameters:
builder1- The first scalar expressionbuilder2- The second scalar expression- Returns:
- This This builder
-
numeric
T numeric(java.lang.Number number)
Creates the numeric literal.- Parameters:
number- The numeric literal- Returns:
- This This builder
-
numeric
T numeric(java.lang.String number)
Creates the numeric literal.- Parameters:
number- The numeric literal- Returns:
- This This builder
-
parameter
T parameter(java.lang.String parameter)
Creates the input parameter.- Parameters:
parameter- The named or positional input parameter- Returns:
- This This builder
-
path
T path(java.lang.String path)
Creates a new state field path expression.- Parameters:
path- The state field path path expression- Returns:
- This This builder
-
plus
T plus(T builder)
Creates the expression+ x.- Parameters:
builder- The expression that will have the plus sign prepended- Returns:
- This This builder
-
size
T size(java.lang.String path)
Creates the expressionSIZE(collection_valued_path_expression).- Parameters:
path- The collection-valued path expression- Returns:
- This This builder
-
sqrt
T sqrt(T builder)
Creates the expressionSQRT(x).- Parameters:
builder- The parameter of theABSexpression- Returns:
- This This builder
-
string
T string(java.lang.String literal)
Creates a new string literal.- Parameters:
literal- The string literal- Returns:
- This This builder
-
sub
T sub(T builder)
Creates an encapsulated expression:(expression).- Parameters:
builder- The expression that will be encapsulated- Returns:
- This This builder
-
subtract
T subtract(T builder)
Creates the expressionx - y.- Parameters:
builder- The right side of the addition expression- Returns:
- This This builder
-
sum
T sum(java.lang.String path)
Creates the expressionSUM(path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
sumDistinct
T sumDistinct(java.lang.String path)
Creates the expressionSUM(path).- Parameters:
path- The state field path expression- Returns:
- This This builder
-
type
T type(java.lang.String path)
Creates the expressionTYPE(identification_variable | single_valued_object_path_expression | input_parameter).- Parameters:
path- The identification variable or the input parameter- Returns:
- This This builder
-
-