简单配置pom.xml详解编程语言

<project xmlns=”http://maven.apache.org/POM/4.0.0″ xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xsi:schemaLocation=”http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd”>
  <modelVersion>4.0.0</modelVersion>
  <groupId>com.shd.ssm</groupId>
  <artifactId>ssm_web</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <packaging>war</packaging>

  <dependencies>
  <!– 导入Oracle数据库链接jar包 –>
  <!– <dependency>
    <groupId>com.oracle</groupId>
    <artifactId>ojdbc6</artifactId>
    <version>11.2.0.1.0</version>
  </dependency> –>

  <!– 1、MySQL database driver –>
  <dependency>
    <groupId>mysql</groupId>
    <artifactId>mysql-connector-java</artifactId>
    <version>5.1.41</version>
  </dependency>

  <dependency>
    <groupId>c3p0</groupId>
    <artifactId>c3p0</artifactId>
    <version>0.9.1.1</version>
  </dependency>

  <!– 导入dbcp的jar包,用来在applicationContext.xml中配置数据库 –>
  <dependency>
    <groupId>commons-dbcp</groupId>
    <artifactId>commons-dbcp</artifactId>
    <version>1.2.2</version>
  </dependency>

  <!– 1、MySQL database driver –>
  <dependency>
    <groupId>mysql</groupId>
    <artifactId>mysql-connector-java</artifactId>
    <version>${mysql_version}</version>
  </dependency>

  <!– 2_1、mybatis framework –>
  <dependency>
    <groupId>org.mybatis</groupId>
    <artifactId>mybatis</artifactId>
    <version>${mybatis_version}</version>
  </dependency>

  <!– 2_2、mybatis 集成 spring 的插件包 : mybatis-spring –>
  <dependency>
    <groupId>org.mybatis</groupId>
    <artifactId>mybatis-spring</artifactId>
    <version>${mybatis-spring_version}</version>
  </dependency>

  <!– 2_3、c3p0 连接池包 –>
  <dependency>
    <groupId>com.mchange</groupId>
    <artifactId>c3p0</artifactId>
    <version>${c3p0_version}</version>
  </dependency>

  <!– 3_1、spring framework –>
  <dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-context</artifactId>
    <version>${spring_version}</version>
  </dependency>

  <!– 3_2、spring-jdbc 目的是为了配置声明式事务 –>
  <dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-web</artifactId>
    <version>${spring_version}</version>
  </dependency>
  <dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-jdbc</artifactId>
    <version>${spring_version}</version>
  </dependency>

  <!– 4_1、springmvc –>
  <dependency>
    <groupId>org.springframework</groupId>
    <artifactId>spring-webmvc</artifactId>
    <version>${spring_version}</version>
  </dependency>

  <!– 5、junit –>
  <dependency>
    <groupId>junit</groupId>
    <artifactId>junit</artifactId>
    <version>${junit_version}</version>
  </dependency>

  <!– log4j –>
  <dependency>
    <groupId>log4j</groupId>
    <artifactId>log4j</artifactId>
    <version>${log4j_version}</version>
  </dependency>

  <!– –>
  <dependency>
    <groupId>org.aspectj</groupId>
    <artifactId>aspectjweaver</artifactId>
    <version>${aspectj_version}</version>
  </dependency>

  <!– servlet –>
  <dependency>
    <groupId>javax.servlet</groupId>
    <artifactId>javax.servlet-api</artifactId>
    <version>3.1.0</version>
    <scope>provided</scope>
  </dependency>

  <!– json-databind –>
  <dependency>
    <groupId>com.fasterxml.jackson.core</groupId>
    <artifactId>jackson-databind</artifactId>
    <version>2.8.5</version>
  </dependency>

  <!– commons-fileupload –>
  <dependency>
    <groupId>commons-fileupload</groupId>
    <artifactId>commons-fileupload</artifactId>
    <version>1.2.1</version>
  </dependency>

  <!– commons-io –>
  <dependency>
    <groupId>commons-io</groupId>
    <artifactId>commons-io</artifactId>
    <version>2.5</version>
  </dependency>

  <dependency>
    <groupId>commons-logging</groupId>
    <artifactId>commons-logging</artifactId>
    <version>1.1.3</version>
  </dependency>
  <dependency>
    <groupId>commons-collections</groupId>
    <artifactId>commons-collections</artifactId>
    <version>3.2.1</version>
  </dependency>

  <!–shiro –>
  <!– <dependency> <groupId>org.apache.shiro</groupId> <artifactId>shiro-core</artifactId>
  <version>1.2.2</version> </dependency> <dependency> <groupId>org.apache.shiro</groupId>
  <artifactId>shiro-web</artifactId> <version>1.2.2</version> </dependency>
  <dependency> <groupId>net.sf.ehcache</groupId> <artifactId>ehcache-core</artifactId>
  <version>2.6.8</version> </dependency> <dependency> <groupId>org.apache.shiro</groupId>
  <artifactId>shiro-ehcache</artifactId> <version>1.2.2</version> </dependency>
  <dependency> <groupId>org.apache.shiro</groupId> <artifactId>shiro-quartz</artifactId>
  <version>1.2.2</version> </dependency> <dependency> <groupId>org.apache.shiro</groupId>
  <artifactId>shiro-spring</artifactId> <version>1.2.2</version> </dependency> –>

  <!– jstl –>
  <dependency>
    <groupId>org.apache.taglibs</groupId>
    <artifactId>taglibs-standard-jstlel</artifactId>
    <version>1.2.5</version>
  </dependency>

 </dependencies>

  <!– 提取出公共的版本属性部分 –>
  <properties>
    <mysql_version>5.1.41</mysql_version>
    <junit_version>4.11</junit_version>
    <log4j_version>1.2.12</log4j_version>
    <mybatis_version>3.2.7</mybatis_version>
    <spring_version>4.2.6.RELEASE</spring_version>
    <mybatis-spring_version>1.2.2</mybatis-spring_version>
    <c3p0_version>0.9.5.2</c3p0_version>
    <aspectj_version>1.8.9</aspectj_version>
  </properties>

</project>

原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/17396.html

(0)
上一篇 2021年7月19日
下一篇 2021年7月19日

相关推荐

发表回复

登录后才能评论