public class SessionBeanDefinitionRegistrarPostProcessor extends Object implements BeanFactoryPostProcessor, PersistenceExceptionTranslator
BeanFactoryPostProcessor
to register a SessionFactoryBeanDefinition
for the
SessionFactory
bean definition found in the application context to enable autowiring
Session
instances into constructor arguments.
A PersistenceExceptionTranslator is added so it gets automatically registered with the Spring exception translation infrastructure.
Constructor and Description |
---|
SessionBeanDefinitionRegistrarPostProcessor() |
Modifier and Type | Method and Description |
---|---|
void |
postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) |
DataAccessException |
translateExceptionIfPossible(RuntimeException ex) |
public SessionBeanDefinitionRegistrarPostProcessor()
public void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) throws BeansException
postProcessBeanFactory
in interface BeanFactoryPostProcessor
BeansException
public DataAccessException translateExceptionIfPossible(RuntimeException ex)
translateExceptionIfPossible
in interface PersistenceExceptionTranslator
Copyright © 2011-2015–2017 Pivotal Software, Inc.. All rights reserved.