diff --git a/hibernate-core/src/main/java/org/hibernate/query/hql/internal/SemanticQueryBuilder.java b/hibernate-core/src/main/java/org/hibernate/query/hql/internal/SemanticQueryBuilder.java index 09f34d1339..4151f1941c 100644 --- a/hibernate-core/src/main/java/org/hibernate/query/hql/internal/SemanticQueryBuilder.java +++ b/hibernate-core/src/main/java/org/hibernate/query/hql/internal/SemanticQueryBuilder.java @@ -2533,7 +2533,7 @@ public class SemanticQueryBuilder extends HqlParserBaseVisitor implements SqmCre final SqmPathSource pluralAttribute = sqmFrom.getReferencedPathSource(); if ( !( pluralAttribute instanceof PluralPersistentAttribute ) ) { - throw new ParsingException( "Could not resolve identification variable [" + alias + "] as plural-attribute" ) + throw new ParsingException( "Could not resolve identification variable [" + alias + "] as plural-attribute" ); } //noinspection unchecked diff --git a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/CollectionJavaTypeDescriptor.java b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/CollectionJavaTypeDescriptor.java index 65af41bc97..1fc4cded88 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/CollectionJavaTypeDescriptor.java +++ b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/CollectionJavaTypeDescriptor.java @@ -8,7 +8,7 @@ package org.hibernate.type.descriptor.java.spi; import org.hibernate.collection.spi.CollectionSemantics; import org.hibernate.collection.spi.PersistentCollection; -import org.hibernate.engine.spi.SharedSessionContractImplementor; +import org.hibernate.type.descriptor.WrapperOptions; import org.hibernate.type.descriptor.java.AbstractTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptorIndicators; @@ -48,12 +48,12 @@ public class CollectionJavaTypeDescriptor extends AbstractTypeDescriptor { } @Override - public X unwrap(C value, Class type, SharedSessionContractImplementor session) { + public X unwrap(C value, Class type, WrapperOptions options) { throw new UnsupportedOperationException( ); } @Override - public C wrap(X value, SharedSessionContractImplementor session) { + public C wrap(X value, WrapperOptions options) { throw new UnsupportedOperationException( ); } diff --git a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/EnumJavaDescriptor.java b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/EnumJavaDescriptor.java index fb4d506d8e..08f617b740 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/EnumJavaDescriptor.java +++ b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/EnumJavaDescriptor.java @@ -9,7 +9,7 @@ package org.hibernate.type.descriptor.java.spi; import java.sql.Types; import javax.persistence.EnumType; -import org.hibernate.engine.spi.SharedSessionContractImplementor; +import org.hibernate.type.descriptor.WrapperOptions; import org.hibernate.type.descriptor.java.AbstractTypeDescriptor; import org.hibernate.type.descriptor.java.ImmutableMutabilityPlan; import org.hibernate.type.descriptor.sql.SqlTypeDescriptor; @@ -52,13 +52,13 @@ public class EnumJavaDescriptor extends AbstractTypeDescriptor X unwrap(E value, Class type, SharedSessionContractImplementor session) { + public X unwrap(E value, Class type, WrapperOptions options) { return (X) value; } @Override @SuppressWarnings("unchecked") - public E wrap(X value, SharedSessionContractImplementor session) { + public E wrap(X value, WrapperOptions options) { return (E) value; } diff --git a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorBasicAdaptor.java b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorBasicAdaptor.java index 2ffab1dc9f..ff21a1e013 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorBasicAdaptor.java +++ b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorBasicAdaptor.java @@ -6,7 +6,7 @@ */ package org.hibernate.type.descriptor.java.spi; -import org.hibernate.engine.spi.SharedSessionContractImplementor; +import org.hibernate.type.descriptor.WrapperOptions; import org.hibernate.type.descriptor.java.AbstractTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptorIndicators; @@ -42,14 +42,14 @@ public class JavaTypeDescriptorBasicAdaptor extends AbstractTypeDescriptor } @Override - public X unwrap(T value, Class type, SharedSessionContractImplementor session) { + public X unwrap(T value, Class type, WrapperOptions options) { throw new UnsupportedOperationException( "Unwrap strategy not known for this Java type : " + getJavaType().getName() ); } @Override - public T wrap(X value, SharedSessionContractImplementor session) { + public T wrap(X value, WrapperOptions options) { throw new UnsupportedOperationException( "Wrap strategy not known for this Java type : " + getJavaType().getName() ); diff --git a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorRegistry.java b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorRegistry.java index 41b64e6ab5..d5750c8c91 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorRegistry.java +++ b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/JavaTypeDescriptorRegistry.java @@ -11,8 +11,8 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.function.Supplier; import org.hibernate.boot.model.TypeContributor; -import org.hibernate.engine.spi.SharedSessionContractImplementor; import org.hibernate.internal.util.SerializationHelper; +import org.hibernate.type.descriptor.WrapperOptions; import org.hibernate.type.descriptor.java.AbstractTypeDescriptor; import org.hibernate.type.descriptor.java.JavaTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptor; @@ -171,7 +171,7 @@ public class JavaTypeDescriptorRegistry implements JavaTypeDescriptorBaseline.Ba } @Override - public X unwrap(T value, Class type, SharedSessionContractImplementor session) { + public X unwrap(T value, Class type, WrapperOptions options) { if ( type.equals( byte[].class ) ) { throw new UnsupportedOperationException( "Cannot unwrap Serializable to format other than byte[]" ); } @@ -181,7 +181,7 @@ public class JavaTypeDescriptorRegistry implements JavaTypeDescriptorBaseline.Ba @Override @SuppressWarnings("unchecked") - public T wrap(X value, SharedSessionContractImplementor session) { + public T wrap(X value, WrapperOptions options) { if ( value == null ) { return null; } diff --git a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/MapEntryJavaDescriptor.java b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/MapEntryJavaDescriptor.java index 1f3bd38e9a..e1a4a8c3e9 100644 --- a/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/MapEntryJavaDescriptor.java +++ b/hibernate-core/src/main/java/org/hibernate/type/descriptor/java/spi/MapEntryJavaDescriptor.java @@ -8,7 +8,7 @@ package org.hibernate.type.descriptor.java.spi; import java.util.Map; -import org.hibernate.engine.spi.SharedSessionContractImplementor; +import org.hibernate.type.descriptor.WrapperOptions; import org.hibernate.type.descriptor.java.AbstractTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptor; import org.hibernate.type.descriptor.sql.SqlTypeDescriptorIndicators; @@ -37,12 +37,12 @@ public class MapEntryJavaDescriptor extends AbstractTypeDescriptor { } @Override - public X unwrap(Map.Entry value, Class type, SharedSessionContractImplementor session) { + public X unwrap(Map.Entry value, Class type, WrapperOptions options) { throw new UnsupportedOperationException( "Unsupported attempt to unwrap Map.Entry value" ); } @Override - public Map.Entry wrap(X value, SharedSessionContractImplementor session) { + public Map.Entry wrap(X value, WrapperOptions options) { throw new UnsupportedOperationException( "Unsupported attempt to wrap Map.Entry value" ); } }