一、用eclipse插件搭建项目

二、pom文件

  1 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
3 <modelVersion>4.0.0</modelVersion>
4 <groupId>com</groupId>
5 <artifactId>ssmm</artifactId>
6 <packaging>war</packaging>
7 <version>0.0.1-SNAPSHOT</version>
8 <name>ssmm Maven Webapp</name>
9 <url>http://maven.apache.org</url>
10 <properties>
11 <spring.version>4.0.4.RELEASE</spring.version>
12 </properties>
13 <dependencies>
14 <dependency>
15 <groupId>org.springframework</groupId>
16 <artifactId>spring-core</artifactId>
17 <version>${spring.version}</version>
18 </dependency>
19 <dependency>
20 <groupId>org.springframework</groupId>
21 <artifactId>spring-webmvc</artifactId>
22 <version>${spring.version}</version>
23 </dependency>
24 <dependency>
25 <groupId>org.springframework</groupId>
26 <artifactId>spring-context</artifactId>
27 <version>${spring.version}</version>
28 </dependency>
29 <dependency>
30 <groupId>org.springframework</groupId>
31 <artifactId>spring-context-support</artifactId>
32 <version>${spring.version}</version>
33 </dependency>
34 <dependency>
35 <groupId>org.springframework</groupId>
36 <artifactId>spring-aop</artifactId>
37 <version>${spring.version}</version>
38 </dependency>
39 <dependency>
40 <groupId>org.springframework</groupId>
41 <artifactId>spring-aspects</artifactId>
42 <version>${spring.version}</version>
43 </dependency>
44 <dependency>
45 <groupId>org.springframework</groupId>
46 <artifactId>spring-tx</artifactId>
47 <version>${spring.version}</version>
48 </dependency>
49 <dependency>
50 <groupId>org.springframework</groupId>
51 <artifactId>spring-test</artifactId>
52 <version>${spring.version}</version>
53 <scope>test</scope>
54 </dependency>
55 <dependency>
56 <groupId>org.springframework</groupId>
57 <artifactId>spring-jdbc</artifactId>
58 <version>${spring.version}</version>
59 </dependency>
60 <dependency>
61 <groupId>org.springframework</groupId>
62 <artifactId>spring-web</artifactId>
63 <version>${spring.version}</version>
64 </dependency>
65 <!-- json -->
66 <dependency>
67 <groupId>com.alibaba</groupId>
68 <artifactId>fastjson</artifactId>
69 <version>1.1.39</version>
70 </dependency>
71 <!-- servlet -->
72 <dependency>
73 <groupId>javax.servlet</groupId>
74 <artifactId>servlet-api</artifactId>
75 <version>2.5</version>
76 <scope>provided</scope>
77 </dependency>
78 <!-- 这个是使用velocity的必备包 -->
79 <dependency>
80 <groupId>org.springframework</groupId>
81 <artifactId>spring-context-support</artifactId>
82 <version>3.2.6.RELEASE</version>
83 <scope>compile</scope>
84 </dependency>
85 <!-- mysql -->
86 <dependency>
87 <groupId>mysql</groupId>
88 <artifactId>mysql-connector-java</artifactId>
89 <version>5.1.27</version>
90 <scope>runtime</scope>
91 </dependency>
92 <!-- 数据源 -->
93 <dependency>
94 <groupId>org.apache.tomcat</groupId>
95 <artifactId>tomcat-jdbc</artifactId>
96 <version>7.0.47</version>
97 </dependency>
98 <!-- mybatis -->
99 <dependency>
100 <groupId>org.mybatis</groupId>
101 <artifactId>mybatis</artifactId>
102 <version>3.1.1</version>
103 </dependency>
104 <dependency>
105 <groupId>org.mybatis</groupId>
106 <artifactId>mybatis-spring</artifactId>
107 <version>1.1.1</version>
108 </dependency>
109 <!-- velocity -->
110 <dependency>
111 <groupId>org.apache.velocity</groupId>
112 <artifactId>velocity</artifactId>
113 <version>1.5</version>
114 </dependency>
115 <dependency>
116 <groupId>velocity-tools</groupId>
117 <artifactId>velocity-tools-generic</artifactId>
118 <version>1.2</version>
119 </dependency>
120 </dependencies>
121 <build>
122 <finalName>ssmm</finalName>
123 </build>
124 </project>

pom.xml

三、web.xml

 <?xml version="1.0" encoding="utf-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
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"> <servlet>
<servlet-name>dispatcherServlet</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath*:spring*.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>dispatcherServlet</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping> <filter>
<filter-name>encodingFilter</filter-name>
<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
<init-param>
<param-name>encoding</param-name>
<param-value>UTF-8</param-value>
</init-param>
<init-param>
<param-name>forceEncoding</param-name>
<param-value>true</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>encodingFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping> <welcome-file-list>
<welcome-file>/index.jsp</welcome-file>
</welcome-file-list>
</web-app>

web.xml

springmvc企业级开发实战的更多相关文章

  1. 包建强的培训课程(7):iOS企业级开发实战

    @import url(http://i.cnblogs.com/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/c ...

  2. 包建强的培训课程(1):Android App企业级开发

    @import url(http://i.cnblogs.com/Load.ashx?type=style&file=SyntaxHighlighter.css);@import url(/c ...

  3. Vue企业级优雅实战-00-开篇

    从2018.1.开始参与了多个企业的中台建设,这些中台的技术选型几乎都是基于 Spring Cloud 微服务架构 + 基于 Vue 全家桶的前端.我前后端架构及开发我几乎各占一半的精力,在企业级前端 ...

  4. 图书-技术-SpringBoot:《Spring Boot 企业级应用开发实战》

    ylbtech-图书-技术-SpringBoot:<Spring Boot 企业级应用开发实战> Spring Boot 企业级应用开发实战,全书围绕如何整合以 Spring Boot 为 ...

  5. 《精通Spring 4.X企业应用开发实战》读书笔记1-1(IoC容器和Bean)

    很长一段时间关注在Java Web开发的方向上,提及到Jave Web开发就绕不开Spring全家桶系列,使用面向百度,谷歌的编程方法能够完成大部分的工作.但是这种不系统的了解总觉得自己的知识有所欠缺 ...

  6. iOS企业级开发初级课程-表视图(13集)

    首先了解了表视图的组成.表视图类的构成.表视图的分类以及表视图的两个重要协议(委托协议和数据源协议),对表视图有了一个整体上的认识.接下来我们掌握了如何实现简单表视图和分节表视图,以及表视图中索引.搜 ...

  7. JAVA EE企业级开发四步走完全攻略 [转]

    http://bbs.51cto.com/thread-550558-1.html 本文是J2EE企业级开发四步走完全攻略索引,因内容比较广泛,涉及整个JAVA EE开发相关知识,这是一个长期的计划, ...

  8. Swift项目开发实战-基于分层架构的多版本iPhone计算器-直播公开课

    Swift项目开发实战-基于分层架构的多版本iPhone计算器-直播公开课 本课程采用Q Q群直播方式进行直播,价值99元视频课程免费直播.完整的基于Swift项目实战,手把手教你做一个Swift版i ...

  9. Spring 3.x 实践 第一个例子(Spring 3.x 企业应用开发实战读书笔记第二章)

    前言:工作之后一直在搞android,现在需要更多和后台的人员交涉,技术栈不一样,难免鸡同鸭讲,所以稍稍学习下. 这个例子取自于<Spring 3.x 企业应用开发实战>一书中的第二章,I ...

随机推荐

  1. cut DEMO

    分割后得到列: cat /etc/passwd|head -n 5 | cut -d : -f 1,6

  2. 图示-Centos7完整安装

    工作过程中,一些未接触过Centos,或未安装过Centos的同事经常会问,如何安装?这个事说简单真简单,只有操作过一次,第二次就能够熟练的自己动手安装:但说难也难,如果没人带,第一次安装的时候确实不 ...

  3. js里的匿名函数 数组排序

    // 匿名函数:其实就是函数的简写形式 var method =function(){ alert("123"); } method(); // 匿名函数可以用于事件的处理 fun ...

  4. js 闭包理解

    闭包主要应用于两种情况: 1 函数作为返回值. 2 函数作为参数传递. 第一种举例: function fn(){ var max = 10; return function bar(){ if(x ...

  5. ACM题目————放苹果

    Description 把M个同样的苹果放在N个同样的盘子里,允许有的盘子空着不放,问共有多少种不同的分法?(用K表示)5,1,1和1,5,1 是同一种分法. Input 第一行是测试数据的数目t(0 ...

  6. Linux hrtimer分析(2)

    http://blog.csdn.net/angle_birds/article/details/17375901 本文介绍Linux2.6.29中,配置高精度模式的hrtimer与未配置高精度模式时 ...

  7. easyui的页面等待提示层,即mask

    /* * 使用方法: * 开启:MaskUtil.mask(); * 关闭:MaskUtil.unmask(); * * MaskUtil.mask('其它提示文字...'); */ var Mask ...

  8. easyUI的window包含一个iframe,在iframe中如何关闭window?

    easyUI的window包含一个iframe,在iframe中如何关闭window? parent.$('#win').window('close');

  9. Selenium WebDriver + Python 环境配置

    1.   下载必要工具及安装包 1.1.[Python开发环境] 下载并安装Python 2.7.x版本(当前支持2.x版本,不要下载最新的3.X的版本因为python3并非完全兼容python2) ...

  10. IOS文字属性备注

    // Predefined character attributes for text. If the key is not in the dictionary, then use the defau ...