From 56973f5da427f40b298aa68573b6df597a68a4cd Mon Sep 17 00:00:00 2001 From: Gavin King Date: Wed, 26 Jan 2022 10:22:59 +0100 Subject: [PATCH] remove some operations of SessionFactoryDelegatingImpl --- .../spi/SessionFactoryDelegatingImpl.java | 37 ------------------- 1 file changed, 37 deletions(-) diff --git a/hibernate-core/src/main/java/org/hibernate/engine/spi/SessionFactoryDelegatingImpl.java b/hibernate-core/src/main/java/org/hibernate/engine/spi/SessionFactoryDelegatingImpl.java index 16d892cd0e..af89819721 100644 --- a/hibernate-core/src/main/java/org/hibernate/engine/spi/SessionFactoryDelegatingImpl.java +++ b/hibernate-core/src/main/java/org/hibernate/engine/spi/SessionFactoryDelegatingImpl.java @@ -41,8 +41,6 @@ import org.hibernate.metadata.CollectionMetadata; import org.hibernate.metamodel.model.domain.spi.JpaMetamodelImplementor; import org.hibernate.metamodel.spi.MetamodelImplementor; import org.hibernate.metamodel.spi.RuntimeMetamodelsImplementor; -import org.hibernate.persister.collection.CollectionPersister; -import org.hibernate.persister.entity.EntityPersister; import org.hibernate.proxy.EntityNotFoundDelegate; import org.hibernate.query.BindableType; import org.hibernate.query.criteria.HibernateCriteriaBuilder; @@ -206,41 +204,6 @@ public class SessionFactoryDelegatingImpl implements SessionFactoryImplementor, return delegate.getSqlStringGenerationContext(); } - @Deprecated - public EntityPersister getEntityPersister(String entityName) throws MappingException { - return delegate.getRuntimeMetamodels() - .getMappingMetamodel() - .getEntityDescriptor( entityName ); - } - - @Deprecated - public Map getEntityPersisters() { - // for the time being, leave this calling `MetamodelImplementor` to avoid - // creating the map - return delegate.getMetamodel().entityPersisters(); - } - - @Deprecated - public CollectionPersister getCollectionPersister(String role) throws MappingException { - return delegate.getRuntimeMetamodels() - .getMappingMetamodel() - .getCollectionDescriptor( role ); - } - - @Deprecated - public Map getCollectionPersisters() { - // for the time being, leave this calling `MetamodelImplementor` to avoid - // creating the map - return delegate.getMetamodel().collectionPersisters(); - } - - @Deprecated - public String[] getImplementors(String className) throws MappingException { - // for the time being, leave this calling `MetamodelImplementor` - nothing uses - // this method and this is the only usage of `MetamodelImplementor#getImplementors` - return delegate.getMetamodel().getImplementors(className); - } - @Override public RootGraphImplementor findEntityGraphByName(String name) { return delegate.findEntityGraphByName( name );