SSH框架中新建立实体类后的配置
Posted JOEH60
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了SSH框架中新建立实体类后的配置相关的知识,希望对你有一定的参考价值。
strut 层
public class Sellauthentication extends ActionSupport {
private SellauthenticationService SellauthenticationService;
public SellauthenticationService getSellauthenticationService() {
return SellauthenticationService;
}
public void setSellauthenticationService(
SellauthenticationService sellauthenticationService) {
SellauthenticationService = sellauthenticationService;
}
}
spring 层
public interface SellauthenticationService {
}
public class SellauthenticationServiceImpl implements SellauthenticationService {
private SellauthenticationDao SellauthenticationDao;
public SellauthenticationDao getSellauthenticationDao() {
return SellauthenticationDao;
}
public void setSellauthenticationDao(SellauthenticationDao sellauthenticationDao) {
SellauthenticationDao = sellauthenticationDao;
}
}
hibernate 层
public interface SellauthenticationDao {
}
public class SellauthenticationDaoImpl extends HibernateDaoSupport implements SellauthenticationDao{
}
spring 配置文件
<bean id="Sellauthentication"
class="com.ruituo.showyuu.action.adminuseraction.Sellauthentication" scope="prototype">
<property name="SellauthenticationService" ref="SellauthenticationService" />
</bean>
<bean id="SellauthenticationService" class="com.ruituo.showyuu.service.second.impl.SellauthenticationServiceImpl">
<property name="SellauthenticationDao" ref="SellauthenticationDao"/>
</bean>
<bean id="SellauthenticationDao" class="com.ruituo.showyuu.dao.second.impl.SellauthenticationDaoImpl">
<property name="sessionFactory" ref="sessionFactory"/>
</bean>
以上是关于SSH框架中新建立实体类后的配置的主要内容,如果未能解决你的问题,请参考以下文章