-
service查看全部
-
en sdsdsd查看全部
-
strutsjar包查看全部
-
SSH知識點回顧查看全部
-
從action調用service,再從service調用DAO,這就是三大框架整合到一起的調用順序 基于SSH實現員工管理系統之框架整合篇——Action類交給Spring創建 Action可以使用兩種方式創建: 1.有Struts2自身創建:只需要在struts.xml中進行配置就可以 2.交給Spring進行創建: 先在applicationContext.xml中配置Action,這里id="productAction" <!-- 配置Action --> <bean id="productAction" class="cn.muke.ssh.action.ProductAction" scope="prototype"> <!-- 手動注入Service --> <property name="productService" ref="productService" /> </bean> <!-- 配置業務層 --> <bean id="productService" class="cn.muke.ssh.service.ProductService"> <property name="productDao" ref="productDao" /> </bean> <!-- 配置Dao層 --> <bean id="productDao" class="cn.muke.ssh.dao.ProductDao"> </bean> </beans> 然后在struts.xml中進行配置 <struts> <package name="ssh" extends="struts-default" namespace="/"> <action name="product_*" class="productAction" method="{1}"> </action> </package> </struts> 推薦使用Action的類交給Spring框架創建,因為這樣可以使用AOP來管理,否則Struts2自身創建不支持AOP。查看全部
-
了解jar包查看全部
-
SSH知識點回顧查看全部
-
SSH知識點回顧查看全部
-
學習ssh查看全部
-
一張圖就概括了所有 6666查看全部
-
學查看全部
-
Web層 業務層 持久層 Struts2 Spring Hibernate查看全部
-
hibernate文件查看全部
-
引入框架的配置文件查看全部
舉報
0/150
提交
取消