Struts2 Action : Maven 配置

Struts2 Action 记录 作者: LinkSystem Maven 2017/04/11

Struts2 Action 是我关于Struts2的实践记录,该实践的构建环境以下:

  • IDE : IntelliJ IDEA 2016.3.5

  • Maven : Maven 3.3.9

注意事项

  • 在Ajax的响应中,我是以Json作为响应内容,在基于Struts2引入相关插件即 struts2-json-plugin 来支持Json的响应。

以下是该项目的 pom.xml 文件的代码,需要注意的是该实践仅以Struts2为主,同时该实践的dependency的来源是在The Central Repository可查的。该实践的版本统一在properties

版本模块
<properties>
    <struts2.version>2.5.10</struts2.version>
    <servlet.version>3.1.0</servlet.version>
    <junit.version>4.12</junit.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  </properties>
</project>

依赖模块
<dependencies>
    <dependency>
      <groupId>org.apache.struts</groupId>
      <artifactId>struts2-core</artifactId>
      <version>${struts2.version}</version>
    </dependency>
    
    <dependency>
      <groupId>org.apache.struts</groupId>
      <artifactId>struts2-json-plugin</artifactId>
      <version>${struts2.version}</version>
    </dependency>

    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>javax.servlet-api</artifactId>
      <version>${servlet.version}</version>
    </dependency>

    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>${junit.version}</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值