beans bean id ServiceAuthentificat ion class services ServiceAuthentif

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<beans>
<bean id="ServiceAuthentification" class="services.ServiceAuthentificationV1Impl">
<property name="dao" ref="DAOUser"/>
</bean>
<bean id="DAOUser" class="persistance.UserDAOInjectionSessionFactoryImpl">
<property name="factory" ref="sessionFactory"/>
</bean>
<bean id="MyPersistanceManager" class="persistance.framework.HibernateManagerV2"/>
<bean id="MyDataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
<property name="driverClassName" value="com.mysql.jdbc.Driver" />
<property name="url" value="jdbc:mysql://localhost/formation" />
<property name="username" value="root" />
<property name="password" value="" />
</bean>
<bean id="sessionFactory"
class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="dataSource" ref="MyDataSource" />
<property name="mappingResources">
<list>
<value>entites/User.hbm.xml</value>
</list>
</property>
<property name="hibernateProperties">
<props>
<prop key="hibernate.dialect">org.hibernate.dialect.MySQLDialect</prop>
<prop key="hibernate.show_sql">true</prop>
</props>
</property>
</bean>
</beans>