java.lang.NoClassDefFoundError: org.hibernate.cfg.Configuration解决方法!
点击右边红色标题查看本文完整版:java.lang.NoClassDefFoundError: org.hibernate.cfg.Configuration解决方法!
<?xml version= "1.0 " encoding= "UTF-8 "?>
<beans xmlns= "http://www.springframework.org/schema/beans "
xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance "
xsi:schemaLocation= "http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd ">
<bean name= "/empLogin " class= "EmployeeLoginAction ">
<property name= "empMgr " ref= "EmployeeManagerService "/>
</bean>
<bean id= "EmployeeManagerService " class= "EmployeeManagerServiceImpl ">
<property name= "employeeDAO " ref= "EmployeeDAO "/>
</bean>
<bean id= "EmployeeDAO " class= "EmployeeDAOHibernate " lazy-init= "true ">
property name= "employeeDAO " ref= "EmployeeDAO "/
</bean>
<bean id= "dataSource "
class= "org.springframework.jdbc.datasource.DriverManagerDataSource ">
<property name= "driverClassName "
? value= "oracle.jdbc.driver.OracleDriver "/>
<property name= "url "
? value= "jdbc:oracle:thin:@localhost:1521:sammi "/>
<property name= "username " value= "system "/>
<property name= "password " value= "sammi "/>
</bean>
<bean id= "sessionFactory "
class= "org.springframework.orm.hibernate3.LocalSessionFactoryBean "
destroy-method= "close ">
<property name= "configLocation ">
<value> hibernate.cfg.xml </value>
</property>
<property name= "dataSource " ref= "dataSource "/>
<property name= "mappingResources ">
<list>
? <value> Employee.hbm.xml </value>
</list>
</property>
<property name= "hibernateProperties ">
<props>
? <prop key= "hibernate.dialect ">
? org.hibernate.dialect.Oracle9Dialect
? </prop>
</props>
</property>