Class BinaryArithmeticExpression
java.lang.Object
org.hibernate.sql.ast.tree.expression.BinaryArithmeticExpression
- All Implemented Interfaces:
DomainResultProducer
,SqlSelectionProducer
,Expression
,SqlAstNode
-
Constructor Summary
ConstructorsConstructorDescriptionBinaryArithmeticExpression
(Expression lhsOperand, BinaryArithmeticOperator operator, Expression rhsOperand, BasicValuedMapping resultType) -
Method Summary
Modifier and TypeMethodDescriptionvoid
accept
(SqlAstWalker walker) void
applySqlSelections
(DomainResultCreationState creationState) Used when this producer is a selection in a sub-query.createDomainResult
(String resultVariable, DomainResultCreationState creationState) Produce the domain queryThe type for this expressionGet the left-hand operand.Get the operationGet the right-hand operand.resolveSqlSelection
(DomainResultCreationState creationState) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.hibernate.sql.ast.tree.expression.Expression
createDomainResultSqlSelection, createSqlSelection, getColumnReference
-
Constructor Details
-
BinaryArithmeticExpression
public BinaryArithmeticExpression(Expression lhsOperand, BinaryArithmeticOperator operator, Expression rhsOperand, BasicValuedMapping resultType)
-
-
Method Details
-
getExpressionType
Description copied from interface:Expression
The type for this expression- Specified by:
getExpressionType
in interfaceExpression
-
accept
- Specified by:
accept
in interfaceSqlAstNode
-
createDomainResult
public DomainResult createDomainResult(String resultVariable, DomainResultCreationState creationState) Description copied from interface:DomainResultProducer
Produce the domain query- Specified by:
createDomainResult
in interfaceDomainResultProducer
-
applySqlSelections
Description copied from interface:DomainResultProducer
Used when this producer is a selection in a sub-query. The DomainResult is only needed for root query of a SELECT statement. This default impl assumes this producer is a true (Sql)Expression- Specified by:
applySqlSelections
in interfaceDomainResultProducer
-
resolveSqlSelection
-
getLeftHandOperand
Get the left-hand operand.- Returns:
- The left-hand operand.
-
getOperator
Get the operation- Returns:
- The operation
-
getRightHandOperand
Get the right-hand operand.- Returns:
- The right-hand operand.
-