diff --git a/hibernate-core/src/main/java/org/hibernate/query/criteria/HibernateCriteriaBuilder.java b/hibernate-core/src/main/java/org/hibernate/query/criteria/HibernateCriteriaBuilder.java index 62219014c9..7b0d2030d4 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/criteria/HibernateCriteriaBuilder.java +++ b/hibernate-core/src/main/java/org/hibernate/query/criteria/HibernateCriteriaBuilder.java @@ -644,7 +644,7 @@ public interface HibernateCriteriaBuilder extends CriteriaBuilder { * @param <T> the type of each argument to the parameter * @since 7.0 */ - <T> JpaParameterExpression<List<T>> parameterList(Class<T> paramClass); + <T> JpaParameterExpression<List<T>> listParameter(Class<T> paramClass); /** * Create a multivalued parameter accepting multiple arguments @@ -654,7 +654,7 @@ public interface HibernateCriteriaBuilder extends CriteriaBuilder { * @param <T> the type of each argument to the parameter * @since 7.0 */ - <T> JpaParameterExpression<List<T>> parameterList(Class<T> paramClass, String name); + <T> JpaParameterExpression<List<T>> listParameter(Class<T> paramClass, String name); @Override JpaExpression<String> concat(Expression<String> x, Expression<String> y); diff --git a/hibernate-core/src/main/java/org/hibernate/query/criteria/spi/HibernateCriteriaBuilderDelegate.java b/hibernate-core/src/main/java/org/hibernate/query/criteria/spi/HibernateCriteriaBuilderDelegate.java index 00c00aea00..67d738ff11 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/criteria/spi/HibernateCriteriaBuilderDelegate.java +++ b/hibernate-core/src/main/java/org/hibernate/query/criteria/spi/HibernateCriteriaBuilderDelegate.java @@ -682,13 +682,13 @@ public class HibernateCriteriaBuilderDelegate implements HibernateCriteriaBuilde } @Override - public <T> JpaParameterExpression<List<T>> parameterList(Class<T> paramClass) { - return criteriaBuilder.parameterList( paramClass ); + public <T> JpaParameterExpression<List<T>> listParameter(Class<T> paramClass) { + return criteriaBuilder.listParameter( paramClass ); } @Override - public <T> JpaParameterExpression<List<T>> parameterList(Class<T> paramClass, String name) { - return criteriaBuilder.parameterList( paramClass, name ); + public <T> JpaParameterExpression<List<T>> listParameter(Class<T> paramClass, String name) { + return criteriaBuilder.listParameter( paramClass, name ); } @Override diff --git a/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java b/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java index 78730ff618..7223bdc6b9 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java +++ b/hibernate-core/src/main/java/org/hibernate/query/sqm/internal/SqmCriteriaNodeBuilder.java @@ -1665,12 +1665,12 @@ public class SqmCriteriaNodeBuilder implements NodeBuilder, Serializable { } @Override - public <T> JpaParameterExpression<List<T>> parameterList(Class<T> paramClass) { - return parameterList( paramClass, null ); + public <T> JpaParameterExpression<List<T>> listParameter(Class<T> paramClass) { + return listParameter( paramClass, null ); } @Override - public <T> JpaParameterExpression<List<T>> parameterList(Class<T> paramClass, String name) { + public <T> JpaParameterExpression<List<T>> listParameter(Class<T> paramClass, String name) { final BindableType<List<T>> parameterType = new MultiValueParameterType<>( (Class<List<T>>) (Class) List.class ); return new JpaCriteriaParameter<>( name, parameterType, true, this ); } diff --git a/hibernate-core/src/test/java/org/hibernate/orm/test/query/CteTests.java b/hibernate-core/src/test/java/org/hibernate/orm/test/query/CteTests.java index 6a0ce612eb..6aab25bc07 100644 --- a/hibernate-core/src/test/java/org/hibernate/orm/test/query/CteTests.java +++ b/hibernate-core/src/test/java/org/hibernate/orm/test/query/CteTests.java @@ -502,7 +502,7 @@ public class CteTests { scope.inTransaction( session -> { final HibernateCriteriaBuilder cb = session.getCriteriaBuilder(); - final JpaParameterExpression<List<Integer>> param = cb.parameterList( Integer.class ); + final JpaParameterExpression<List<Integer>> param = cb.listParameter( Integer.class ); final JpaCriteriaQuery<Tuple> cq = cb.createTupleQuery(); final JpaCriteriaQuery<Tuple> baseQuery = cb.createTupleQuery(); diff --git a/hibernate-core/src/test/java/org/hibernate/orm/test/query/criteria/CriteriaBuilderNonStandardFunctionsTest.java b/hibernate-core/src/test/java/org/hibernate/orm/test/query/criteria/CriteriaBuilderNonStandardFunctionsTest.java index a570429ac6..c969f58d03 100644 --- a/hibernate-core/src/test/java/org/hibernate/orm/test/query/criteria/CriteriaBuilderNonStandardFunctionsTest.java +++ b/hibernate-core/src/test/java/org/hibernate/orm/test/query/criteria/CriteriaBuilderNonStandardFunctionsTest.java @@ -521,7 +521,7 @@ public class CriteriaBuilderNonStandardFunctionsTest { HibernateCriteriaBuilder cb = session.getCriteriaBuilder(); CriteriaQuery<Tuple> query = cb.createTupleQuery(); Root<EntityOfBasics> from = query.from(EntityOfBasics.class); - ParameterExpression<List<Integer>> ids = cb.parameterList(Integer.class); + ParameterExpression<List<Integer>> ids = cb.listParameter(Integer.class); query.where( from.get("id").in(ids)); assertEquals(3, session.createQuery( query )