标签:code 建立 还需 font gen -- 通用 start tps
(版本不一样的话可以到maven仓库中找适合自己的版本)
<!-- Servlet依赖 --> <!-- https://mvnrepository.com/artifact/javax.servlet/javax.servlet-api --> <dependency> <groupId>javax.servlet</groupId> <artifactId>javax.servlet-api</artifactId> <version>4.0.1</version> <scope>provided</scope> </dependency>
<!-- JSP依赖 --> <!-- https://mvnrepository.com/artifact/javax.servlet.jsp/javax.servlet.jsp-api --> <dependency> <groupId>javax.servlet.jsp</groupId> <artifactId>javax.servlet.jsp-api</artifactId> <version>2.3.3</version> <scope>provided</scope> </dependency>
<!-- 注册Servlet --> <servlet> <servlet-name>Name</servlet-name> <servlet-class>ClassPath(类的路径:例如com.srx.Servlet.servletTest)</servlet-class> </servlet> <!-- Servlet的请求路径 --> <servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>/Url</url-pattern> </servlet-mapping>
<servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>/Url</url-pattern> </servlet-mapping>
<servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>/Url2</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>/Url3</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>/Url4</url-pattern> </servlet-mapping>
<servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>/Url/*</url-pattern> </servlet-mapping>
<servlet-mapping> <servlet-name>Name</servlet-name> <url-pattern>*.任意后缀</url-pattern> </servlet-mapping>
标签:code 建立 还需 font gen -- 通用 start tps
原文地址:https://www.cnblogs.com/laoqi795/p/12238821.html