SpringMVC 3.1.2的配置(一)

2014-11-24 10:09:09 · 作者: · 浏览: 2

SpringMVC 3.1.2的配置

ssi的框架

web.xml
< xml version="1.0" encoding="UTF-8" >
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
version="2.5">


SpringMVC
org.springframework.web.servlet.DispatcherServlet

contextConfigLocation
/WEB-INF/classes/spring-*.xml

1


SpringMVC
*.do



spring-core.xml
< xml version="1.0" encoding="UTF-8" >

xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop-3.1.xsd
http://www.springframework.org/schema/contex
http://www.springframework.org/schema/context/spring-context-3.1.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx-3.1.xsd">




classpath:jdbc.properties




${jdbc.driver}


${jdbc.url}


${jdbc.user}


${jdbc.password}

class="org.springframework.jdbc.datasource.DataSourceTransactionManager">

class="org.springframework.orm.ibatis.SqlMapClientFactoryBean">



































spring-mvc.xml
< xml version="1.0" encoding="UTF-8" >
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
http://www.springframe