---
title: "SpringMVC中jar包及配置"
author: "weinan"
date: "2015-10-22T10:03:36Z"
tags: []
categories: ["移动开发"]
slug: "springmvc-jar"
draft: false
lastmod: "2015-10-14T10:15:59Z"
id: 2248994
url: "https://weinan.iteye.com/blog/2248994"
---

1.SpringMVC基本包： \[code="java"] 　　org.springframework 　　spring-webmvc 　　4.1.6.RELEASE \[/code] 2.Spring测试包Junit \[code="java"] 　　org.springframework 　　spring-test 　　4.1.6.RELEASE 　　test 　　junit 　　junit 　　4.11 \[/code] 3.Junit测试： \[code="java"]@RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration(locations = { "classpath:/spring/context-aop1.xml" })\[/code] 4.springMVC的web.xml \[code="java"] springMVC-hello log4jConfigLocation classpath:log4j.xml log4jRefreshInterval 60000 webAppRootKey spring.root contextConfigLocation classpath:applicationContext.xml org.springframework.web.context.ContextLoaderListener org.springframework.web.util.IntrospectorCleanupListener org.springframework.web.util.Log4jConfigListener springMVC org.springframework.web.servlet.DispatcherServlet contextConfigLocation classpath:springMVC.xml 1 springMVC / encodingFilter org.springframework.web.filter.CharacterEncodingFilter encoding utf-8 forceEncoding true encodingFilter /* \[/code] 5.springMVC的config.xml \[code="java"] \[/code]