日期:2014-05-17 浏览次数:21058 次
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.1//EN" "http://struts.apache.org/dtds/struts-2.1.dtd">
<struts>
<constant name="struts.devMode" value="true"></constant>
<constant name="struts.objectFactory" value="spring"></constant>
<package name="Microblogging" extends="struts-default">
<action name="UserLoginAndRegist" class="cn.edu.bzu.Microblogging.Action.UserLoginAndRegist">
<result name="success">/jsp/webPage/user_index.jsp</result>
<result name="input">/jsp/prompt/regist_prompt_failure.jsp</result>
</action>
</package>
</struts>
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:p="http://www.springframework.org/schema/p"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop-2.5.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx-2.5.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-2.5.xsd">
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="configLocation"><value>classpath:hibernate.cfg.xml</value></property>
</bean>
<!-- 事务管理器 -->
<bean id="txManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
<property name="sessionFactory" ref="sessionFactory"/>
</bean>
<aop:config proxy-target-class="false">
<aop:pointcut id="transactionPointcut" expression="execution(* cn.edu.bzu.Microblogging..*.*(..))"/>
<aop:advisor advice-ref="txAdvice" pointcut-ref="transactionPointcut"/>
</aop:config>
<!-- 通知 -->
<tx:advice id="txAdvice" transaction-manager="txManager">
<tx:attributes>
<tx:method name="get*" read-only="true" propagation="NOT_SUPPORTED"/>
<tx:method name="*"/>
</tx:attributes>
</tx:advice>
<!-- Spring自动扫描 -->
<context:component-scan base-package="cn.edu.bzu.Microblogging"/>
</beans>
推荐阅读更多>
-
(function(){//coding.})() 请教这是什么意思
-
socket没法从服务端判断是否客户端已启动
-
快期末了,真心请问一道期中考试题
-
myeclipse打开的时候总是自动打开,以前还有选择哪个工作空间的,给位有哪位高手知道在哪里设置的么
-
关于创建进程,该怎么解决
-
求高手点拨“将小弟我的聊天界面增加:根据用户的输入文本焦点”进行跟踪显示的“留言板”功能
-
Tomcat6.0配置到MyEclipse 10启动异常,但单独启动tomcat是正常的
-
hibernate 注解疑问,望.
-
java怎么组装多层嵌套json
-
jsp中怎么跳转到数据库中输入的网页
-
求教!dateFormat.parse cannot be resolved to a type,该如何处理
-
Jsoup的有关问题。
-
求解poi中的characterRun是干什么用的?解决办法
-
关于流(初学),该如何解决
-
JAVA学习迷惑之设计模式
-
jfreechart 1.0.12中文无法正常解决方法
-
小弟我的eclipse打不开类了
-
VM中安装VM TOOLS出现有关问题
-
在应用quartz框架的时候添加CronTrigger的时候无法确定第一次执行的时间
-
大家伙儿帮个忙,有关JAVA输出