Class ArrayAndElementArgumentTypeResolver

java.lang.Object
org.hibernate.dialect.function.array.ArrayAndElementArgumentTypeResolver
All Implemented Interfaces:
FunctionArgumentTypeResolver, org.hibernate.query.sqm.produce.function.internal.AbstractFunctionArgumentTypeResolver

public class ArrayAndElementArgumentTypeResolver extends Object implements org.hibernate.query.sqm.produce.function.internal.AbstractFunctionArgumentTypeResolver
A FunctionArgumentTypeResolver that resolves the array argument type based on the element argument type or the element argument type based on the array argument type.
  • Field Details

  • Constructor Details

    • ArrayAndElementArgumentTypeResolver

      public ArrayAndElementArgumentTypeResolver(int arrayIndex, int... elementIndexes)
  • Method Details

    • resolveFunctionArgumentType

      public @Nullable MappingModelExpressible<?> resolveFunctionArgumentType(List<? extends SqmTypedNode<?>> arguments, int argumentIndex, SqmToSqlAstConverter converter)
      Description copied from interface: FunctionArgumentTypeResolver
      Resolve the argument type for a function given its context-implied return type.

      The context-implied type is the type implied by where the function occurs in the query. E.g., for an equality predicate (`something = some_function`) the implied type would be defined by the type of `something`.

      Specified by:
      resolveFunctionArgumentType in interface org.hibernate.query.sqm.produce.function.internal.AbstractFunctionArgumentTypeResolver
      Specified by:
      resolveFunctionArgumentType in interface FunctionArgumentTypeResolver
      Returns:
      The resolved type.