Package org.hibernate.query.sqm.function
Class AbstractSqmSelfRenderingFunctionDescriptor
- java.lang.Object
-
- org.hibernate.query.sqm.function.AbstractSqmFunctionDescriptor
-
- org.hibernate.query.sqm.function.AbstractSqmSelfRenderingFunctionDescriptor
-
- All Implemented Interfaces:
FunctionRenderer,FunctionRenderingSupport,SqmFunctionDescriptor
- Direct Known Subclasses:
AbstractArrayContainsFunction,AbstractArrayFillFunction,AbstractArrayIncludesFunction,AbstractArrayIntersectsFunction,AbstractArrayPositionFunction,AbstractArrayPositionsFunction,AbstractArrayRemoveFunction,AbstractArrayTrimFunction,ArrayAggFunction,ArrayConcatElementFunction,ArrayConcatFunction,ArrayConstructorFunction,ArrayGetUnnestFunction,ArrayRemoveIndexUnnestFunction,ArrayReplaceUnnestFunction,ArraySetUnnestFunction,ArraySliceUnnestFunction,ArrayToStringFunction,AvgFunction,CaseLeastGreatestEmulation,CastFunction,CastingConcatFunction,ChrLiteralEmulation,ConcatPipeFunction,CountFunction,CurrentFunction,DB2PositionFunction,DB2SubstringFunction,DerbyLpadEmulation,DerbyRpadEmulation,EveryAnyEmulation,HypotheticalSetFunction,InverseDistributionFunction,LengthFunction,ListaggFunction,ListaggGroupConcatEmulation,ListaggStringAggEmulation,MinMaxCaseEveryAnyEmulation,NamedSqmFunctionDescriptor,OracleArrayAggEmulation,OracleArrayLengthFunction,PatternBasedSqmFunctionDescriptor,PostgreSQLMinMaxFunction,QuantifiedLeastGreatestEmulation,SqlColumn,SqlFunction,SQLServerEveryAnyEmulation,TimestampaddFunction,TimestampdiffFunction,TrimFunction
public abstract class AbstractSqmSelfRenderingFunctionDescriptor extends AbstractSqmFunctionDescriptor implements FunctionRenderer
-
-
Constructor Summary
Constructors Constructor Description AbstractSqmSelfRenderingFunctionDescriptor(String name, FunctionKind functionKind, ArgumentsValidator argumentsValidator, FunctionReturnTypeResolver returnTypeResolver, FunctionArgumentTypeResolver argumentTypeResolver)AbstractSqmSelfRenderingFunctionDescriptor(String name, ArgumentsValidator argumentsValidator, FunctionReturnTypeResolver returnTypeResolver, FunctionArgumentTypeResolver argumentTypeResolver)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T> SelfRenderingSqmAggregateFunction<T>generateSqmAggregateFunctionExpression(List<? extends SqmTypedNode<?>> arguments, SqmPredicate filter, ReturnableType<T> impliedResultType, QueryEngine queryEngine)Return an SQM node or subtree representing an invocation of this aggregate function with the given arguments.protected <T> SelfRenderingSqmFunction<T>generateSqmFunctionExpression(List<? extends SqmTypedNode<?>> arguments, ReturnableType<T> impliedResultType, QueryEngine queryEngine)Return an SQM node or subtree representing an invocation of this function with the given arguments.<T> SelfRenderingSqmOrderedSetAggregateFunction<T>generateSqmOrderedSetAggregateFunctionExpression(List<? extends SqmTypedNode<?>> arguments, SqmPredicate filter, SqmOrderByClause withinGroupClause, ReturnableType<T> impliedResultType, QueryEngine queryEngine)Return an SQM node or subtree representing an invocation of this ordered set-aggregate function with the given arguments.protected <T> SelfRenderingSqmWindowFunction<T>generateSqmWindowFunctionExpression(List<? extends SqmTypedNode<?>> arguments, SqmPredicate filter, Boolean respectNulls, Boolean fromFirst, ReturnableType<T> impliedResultType, QueryEngine queryEngine)Return an SQM node or subtree representing an invocation of this window function with the given arguments.FunctionKindgetFunctionKind()What sort of function is this?voidrender(SqlAppender sqlAppender, List<? extends SqlAstNode> sqlAstArguments, ReturnableType<?> returnType, SqlAstTranslator<?> walker)-
Methods inherited from class org.hibernate.query.sqm.function.AbstractSqmFunctionDescriptor
generateAggregateSqmExpression, generateOrderedSetAggregateSqmExpression, generateSqmExpression, generateWindowSqmExpression, getArgumentListSignature, getArgumentsValidator, getArgumentTypeResolver, getName, getReturnSignature, getReturnTypeResolver, getSignature
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.hibernate.query.sqm.function.FunctionRenderer
render, render, render, render
-
Methods inherited from interface org.hibernate.query.sqm.function.FunctionRenderingSupport
render, render, render
-
Methods inherited from interface org.hibernate.query.sqm.function.SqmFunctionDescriptor
alwaysIncludesParentheses, generateSqmExpression, generateSqmExpression
-
-
-
-
Constructor Detail
-
AbstractSqmSelfRenderingFunctionDescriptor
public AbstractSqmSelfRenderingFunctionDescriptor(String name, ArgumentsValidator argumentsValidator, FunctionReturnTypeResolver returnTypeResolver, FunctionArgumentTypeResolver argumentTypeResolver)
-
AbstractSqmSelfRenderingFunctionDescriptor
public AbstractSqmSelfRenderingFunctionDescriptor(String name, FunctionKind functionKind, ArgumentsValidator argumentsValidator, FunctionReturnTypeResolver returnTypeResolver, FunctionArgumentTypeResolver argumentTypeResolver)
-
-
Method Detail
-
render
public void render(SqlAppender sqlAppender, List<? extends SqlAstNode> sqlAstArguments, ReturnableType<?> returnType, SqlAstTranslator<?> walker)
- Specified by:
renderin interfaceFunctionRenderer- Specified by:
renderin interfaceFunctionRenderingSupport
-
getFunctionKind
public FunctionKind getFunctionKind()
Description copied from interface:SqmFunctionDescriptorWhat sort of function is this?- Specified by:
getFunctionKindin interfaceSqmFunctionDescriptor- Returns:
FunctionKind.NORMALby default
-
generateSqmFunctionExpression
protected <T> SelfRenderingSqmFunction<T> generateSqmFunctionExpression(List<? extends SqmTypedNode<?>> arguments, ReturnableType<T> impliedResultType, QueryEngine queryEngine)
Description copied from class:AbstractSqmFunctionDescriptorReturn an SQM node or subtree representing an invocation of this function with the given arguments. This method may be overridden in the case of function descriptors that wish to customize creation of the node.- Specified by:
generateSqmFunctionExpressionin classAbstractSqmFunctionDescriptor- Parameters:
arguments- the arguments of the function invocationimpliedResultType- the function return type as inferred from its usage
-
generateSqmAggregateFunctionExpression
public <T> SelfRenderingSqmAggregateFunction<T> generateSqmAggregateFunctionExpression(List<? extends SqmTypedNode<?>> arguments, SqmPredicate filter, ReturnableType<T> impliedResultType, QueryEngine queryEngine)
Description copied from class:AbstractSqmFunctionDescriptorReturn an SQM node or subtree representing an invocation of this aggregate function with the given arguments. This method may be overridden in the case of function descriptors that wish to customize creation of the node.- Overrides:
generateSqmAggregateFunctionExpressionin classAbstractSqmFunctionDescriptor- Parameters:
arguments- the arguments of the function invocationimpliedResultType- the function return type as inferred from its usage
-
generateSqmOrderedSetAggregateFunctionExpression
public <T> SelfRenderingSqmOrderedSetAggregateFunction<T> generateSqmOrderedSetAggregateFunctionExpression(List<? extends SqmTypedNode<?>> arguments, SqmPredicate filter, SqmOrderByClause withinGroupClause, ReturnableType<T> impliedResultType, QueryEngine queryEngine)
Description copied from class:AbstractSqmFunctionDescriptorReturn an SQM node or subtree representing an invocation of this ordered set-aggregate function with the given arguments. This method may be overridden in the case of function descriptors that wish to customize creation of the node.- Overrides:
generateSqmOrderedSetAggregateFunctionExpressionin classAbstractSqmFunctionDescriptor- Parameters:
arguments- the arguments of the function invocationimpliedResultType- the function return type as inferred from its usage
-
generateSqmWindowFunctionExpression
protected <T> SelfRenderingSqmWindowFunction<T> generateSqmWindowFunctionExpression(List<? extends SqmTypedNode<?>> arguments, SqmPredicate filter, Boolean respectNulls, Boolean fromFirst, ReturnableType<T> impliedResultType, QueryEngine queryEngine)
Description copied from class:AbstractSqmFunctionDescriptorReturn an SQM node or subtree representing an invocation of this window function with the given arguments. This method may be overridden in the case of function descriptors that wish to customize creation of the node.- Overrides:
generateSqmWindowFunctionExpressionin classAbstractSqmFunctionDescriptor- Parameters:
arguments- the arguments of the function invocationimpliedResultType- the function return type as inferred from its usage
-
-