搭建ssh框架的步骤
发布日期:2021-05-14 12:55:20 浏览次数:21 分类:精选文章

本文共 2660 字,大约阅读时间需要 8 分钟。

������������������������������

������������������ Struts���Spring ��� Hibernate ��� Web ������

  • ������ Web ������

    ������������������������������������������������ Web ������������������������������������������������������������

  • ������ SSH jar ���

    ������������ web-inf/lib ��������������������� jar ������

    • hibernate.jar
    • hibernate tools.jar
    • javax.persistence.jar
    • spring.jar
  • ������ Hibernate

    ��� hibernate.cfg.xml ���������������������������

    jdbc:mysql://localhost:3306/database
    root
    root

    ������������������ SQL ������������������ hibernate.cfg.xml ������������������������

    true
    true
  • ������ Hibernate ������

    ��� MyEclipse ��������������������������������������������������� MyEclipse > Add Hibernate Support���������������������������������������������

  • ���������������

    ��� src > org.entity ������������������������ Student ���������������.access=transient��������������������������������������������������������������������� DAO ��� Service ���������

  • ������ Struts

    ������������������������ MyEclipse > Add Struts Support��������������������� Struts ��������������������������� StudentAction���

  • ������ Spring ��� AOP

    ��� applicationContext.xml ���������������������������������������������������������������������������������������������������

  • ���������������������������

    ��������������������������� MyEclipse > Reverse Engineer������������������������������������������������������������������������

  • ������ Struts ��� Spring

    ��� struts.xml ���������������������������������������

    ��� index.jsp ��������������������������������������������������� Struts ��� c:foreach ������������������������������������

  • ������ DAO ��� Service ���������

    ��� DAO ������������ StudentDaoImpl��������� HibernateDaoSupport ��������� IStudentDao ������������ Service ������������ StudentServiceImpl��������� StudentDao ��������� IStudentService���

  • ������ transactionManager ��� advisory

    ������ applicationContext.xml ������ LocalSessionFactoryBean ��� HibernateTransactionManager ���������������������

  • ���������������

    ��� action ������������ StudentAction��������� ActionSupport ��������������������������������������� Service ������ DAO ���������������������������

  • ������ struts.xml

    ������������������ interceptor������������

    ������ URL ������������������������������������������������������������

  • ��������������� Tomcat

    ������������������ Tomcat ��� webapps ������������������������������������������������������������������

  • ��������������������������������������������� Struts���Spring ��� Hibernate ��� Web ������������������������������������������������������������������������������������������������������

    上一篇:《金色梦乡》金句摘抄(八)
    下一篇:《金色梦乡》金句摘抄(七)

    发表评论

    最新留言

    第一次来,支持一个
    [***.219.124.196]2025年04月21日 22时42分55秒

    关于作者

        喝酒易醉,品茶养心,人生如梦,品茶悟道,何以解忧?唯有杜康!
    -- 愿君每日到此一游!

    推荐文章