社区
Web 开发
帖子详情
请问如何配置WEB.XML?听说SCWCD中考了不少,急~~~~
deeprising
2002-05-01 11:34:47
如题
...全文
80
2
打赏
收藏
请问如何配置WEB.XML?听说SCWCD中考了不少,急~~~~
如题
复制链接
扫一扫
分享
举报
写回复
配置赞助广告
用AI写文章
2 条
回复
切换为时间正序
请发表友善的回复…
发表回复
打赏红包
deeprising
2002-05-07
打赏
举报
回复
谢谢~~~请问在tomcat,resin等中配置都一样吗
cxmlc
2002-05-04
打赏
举报
回复
<?xml version="1.0" encoding="UTF-8" ?>
- <!-- edited with XML Spy v3.5 NT (http://www.xmlspy.com) by ()
-->
<!DOCTYPE web-app (View Source for full doctype...)>
- <web-app>
<display-name>SCWCD</display-name>
<description>学习配置DD</description>
- <context-param>
<param-name>user</param-name>
<param-value>scwd</param-value>
</context-param>
- <context-param>
<param-name>password</param-name>
<param-value>scwcd</param-value>
</context-param>
- <listener>
<listener-class>javax.servlet.http.HttpSessionListener</listener-class>
</listener>
- <servlet>
<servlet-name>index</servlet-name>
<servlet-class>servlets.index</servlet-class>
- <init-param>
<param-name>name</param-name>
<param-value>servlet</param-value>
</init-param>
- <init-param>
<param-name>password</param-name>
<param-value>scwcd</param-value>
</init-param>
- <security-role-ref>
<role-name>my</role-name>
</security-role-ref>
</servlet>
- <servlet-mapping>
<servlet-name>index</servlet-name>
<url-pattern>/index</url-pattern>
</servlet-mapping>
- <session-config>
<session-timeout>30</session-timeout>
</session-config>
- <mime-mapping>
<extension>html</extension>
<mime-type>text/html</mime-type>
</mime-mapping>
- <mime-mapping>
<extension>doc</extension>
<mime-type>application/msword</mime-type>
</mime-mapping>
- <welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>index.htm</welcome-file>
</welcome-file-list>
- <error-page>
<error-code>404</error-code>
<location>error/404.html</location>
</error-page>
- <error-page>
<exception-type>java.lang.Exception</exception-type>
<location>error/exception.html</location>
</error-page>
- <taglib>
<taglib-uri>/mytld</taglib-uri>
<taglib-location>/WEB-INF/tlds/mytld/tld</taglib-location>
</taglib>
- <security-constraint>
- <web-resource-collection>
<web-resource-name>my</web-resource-name>
<url-pattern>/index</url-pattern>
<url-pattern>/admin/*</url-pattern>
<http-method>get</http-method>
</web-resource-collection>
- <auth-constraint>
<description>Secury Test</description>
<role-name>Admin</role-name>
</auth-constraint>
- <user-data-constraint>
<transport-guarantee>NONE</transport-guarantee>
</user-data-constraint>
</security-constraint>
- <login-config>
<auth-method>FORM</auth-method>
<realm-name>Form Based Scuruty</realm-name>
- <form-login-config>
<form-login-page>/login.html</form-login-page>
<form-error-page>/error.html</form-error-page>
</form-login-config>
</login-config>
- <security-role>
<role-name>my</role-name>
<description>这是一个安全规则</description>
</security-role>
</web-app>
Makefile中3个常用自动化变量
在Makefile,有三个常用也很好用的自动化变量:$@、$^、$<,所谓自动化变量是在模式规则中定义的一系列文件自动挨个的去除,直至所有的符合模式的文件都取完。这么说可能比较绕,我们可以简单直白的理解,我们写的应用程序,稍微简单的也要有几个文件(.c、.h等),那么复杂的可能有几百,几千,甚至几十万(kernel),我们在编写Makefile时,如果逐个文件去编译,链接,那是绝不可...
Makefile中的自动化变量
以下内容源于C语言中文网的学习与整理,非原创,如有侵权请告知删除。
Makefile变量的定义与使用与自动化变量
变量对于我们来说是不陌生的,在学习各种编程语言时会经常用到。就拿C语言来说,变量的使用是十分常见的,变量可以用来保存一个值或者是使用变量进行运算操作。Makefile 中的变量也是这样,我们可以利用它来表示某些多处使用而又可能发生变化的内容,不仅可以节省重复修改的工作,还可以避免遗漏。Makefile 文件中定义变量的基本语法如下:变量的名称=值列表Makefile 中的变量的使用其实非常的简单,因为它并没有像其它语言那样定义变量的时候需要使用数据类型。
初识 Makefile 自动化
使用 Makefile 做自动化编译. .PHONY: version build modules BUILD_FLAGS = CGO_ENABLED=0 GOOS=linux GOARCH=amd64 BUILD_OBJECT = toolman GO = go VERSION = $(shell git tag --sort=committerdate | tail -n 1) COMPRESS_OBJECT = $(BUILD_OBJECT)-$(VERSION).tar.gz COMPRESS
Makefile 变量
是指 Makefile 执行完后,外部的环境变量并不会改变(这是由于makefile 是 fork 出子进程去执行 command )注意事项,define 定义作为变量,则不能在 makefile 中 使用,需要导出作为环境变量使用。Makefile中变量名和外部环境变量名相同时,会临时覆盖环境变量,会判断是否设置过,没设置过才赋值,设置过就使用原来的值。Makefile中为我们定义好的变量,拿来使用即可。赋值,最右边的只取当前值,即为最终值。赋值在重新赋值时,都会覆盖原有的值。赋值,只取最后设置的值。
Web 开发
81,108
社区成员
341,721
社区内容
发帖
与我相关
我的任务
Web 开发
Java Web 开发
复制链接
扫一扫
分享
社区描述
Java Web 开发
社区管理员
加入社区
获取链接或二维码
近7日
近30日
至今
加载中
查看更多榜单
社区公告
暂无公告
试试用AI创作助手写篇文章吧
+ 用AI写文章