mirror of
https://github.com/spring-projects/spring-framework.git
synced 2026-09-21 21:39:05 +00:00
fixed JavaConfig example
git-svn-id: https://src.springframework.org/svn/spring-framework/trunk@1433 50f2f4bb-b051-0410-bef5-90022cba6387
This commit is contained in:
@@ -343,10 +343,12 @@ public class AppConfig{
|
||||
|
||||
@Bean
|
||||
public SessionFactory sessionFactory() {
|
||||
// wire up a session factory using
|
||||
// AnnotationSessionFactoryBean
|
||||
// wire up a session factory
|
||||
AnnotationSessionFactoryBean asFactoryBean =
|
||||
new AnnotationSessionFactoryBean();
|
||||
asFactoryBean.setDataSource(dataSource());
|
||||
return (SessionFactory) asFactoryBean.getObject();
|
||||
// additional config
|
||||
return asFactoryBean.getObject();
|
||||
}
|
||||
|
||||
@Bean
|
||||
|
||||
Reference in New Issue
Block a user