/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.catalina.core;
import java.io.BufferedReader;
import java.io.File;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.net.MalformedURLException;
import java.net.URL;
import java.security.AccessController;
import java.security.PrivilegedAction;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
import java.util.Enumeration;
import java.util.EventListener;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
import java.util.Stack;
import java.util.TreeMap;
import java.util.concurrent.atomic.AtomicLong;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReadWriteLock;
import java.util.concurrent.locks.ReentrantReadWriteLock;
import javax.management.ListenerNotFoundException;
import javax.management.MBeanNotificationInfo;
import javax.management.Notification;
import javax.management.NotificationBroadcasterSupport;
import javax.management.NotificationEmitter;
import javax.management.NotificationFilter;
import javax.management.NotificationListener;
import javax.naming.NamingException;
import javax.servlet.Filter;
import javax.servlet.FilterConfig;
import javax.servlet.FilterRegistration;
import javax.servlet.RequestDispatcher;
import javax.servlet.Servlet;
import javax.servlet.ServletContainerInitializer;
import javax.servlet.ServletContext;
import javax.servlet.ServletContextAttributeListener;
import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;
import javax.servlet.ServletException;
import javax.servlet.ServletRegistration;
import javax.servlet.ServletRegistration.Dynamic;
import javax.servlet.ServletRequest;
import javax.servlet.ServletRequestAttributeListener;
import javax.servlet.ServletRequestEvent;
import javax.servlet.ServletRequestListener;
import javax.servlet.ServletSecurityElement;
import javax.servlet.SessionCookieConfig;
import javax.servlet.SessionTrackingMode;
import javax.servlet.descriptor.JspConfigDescriptor;
import javax.servlet.http.HttpSessionAttributeListener;
import javax.servlet.http.HttpSessionIdListener;
import javax.servlet.http.HttpSessionListener;
import org.apache.catalina.Authenticator;
import org.apache.catalina.Cluster;
import org.apache.catalina.Container;
import org.apache.catalina.ContainerListener;
import org.apache.catalina.Context;
import org.apache.catalina.Globals;
import org.apache.catalina.InstanceListener;
import org.apache.catalina.Lifecycle;
import org.apache.catalina.LifecycleException;
import org.apache.catalina.LifecycleListener;
import org.apache.catalina.LifecycleState;
import org.apache.catalina.Loader;
import org.apache.catalina.Manager;
import org.apache.catalina.Pipeline;
import org.apache.catalina.Realm;
import org.apache.catalina.ThreadBindingListener;
import org.apache.catalina.Valve;
import org.apache.catalina.WebResource;
import org.apache.catalina.WebResourceRoot;
import org.apache.catalina.Wrapper;
import org.apache.catalina.deploy.NamingResourcesImpl;
import org.apache.catalina.loader.WebappLoader;
import org.apache.catalina.session.StandardManager;
import org.apache.catalina.util.CharsetMapper;
import org.apache.catalina.util.ContextName;
import org.apache.catalina.util.ExtensionValidator;
import org.apache.catalina.util.URLEncoder;
import org.apache.catalina.webresources.StandardRoot;
import org.apache.juli.logging.Log;
import org.apache.juli.logging.LogFactory;
import org.apache.naming.ContextBindings;
import org.apache.tomcat.InstanceManager;
import org.apache.tomcat.JarScanner;
import org.apache.tomcat.util.ExceptionUtils;
import org.apache.tomcat.util.IntrospectionUtils;
import org.apache.tomcat.util.buf.UDecoder;
import org.apache.tomcat.util.descriptor.XmlIdentifiers;
import org.apache.tomcat.util.descriptor.web.ApplicationListener;
import org.apache.tomcat.util.descriptor.web.ApplicationParameter;
import org.apache.tomcat.util.descriptor.web.ErrorPage;
import org.apache.tomcat.util.descriptor.web.FilterDef;
import org.apache.tomcat.util.descriptor.web.FilterMap;
import org.apache.tomcat.util.descriptor.web.Injectable;
import org.apache.tomcat.util.descriptor.web.InjectionTarget;
import org.apache.tomcat.util.descriptor.web.LoginConfig;
import org.apache.tomcat.util.descriptor.web.MessageDestination;
import org.apache.tomcat.util.descriptor.web.MessageDestinationRef;
import org.apache.tomcat.util.descriptor.web.SecurityCollection;
import org.apache.tomcat.util.descriptor.web.SecurityConstraint;
import org.apache.tomcat.util.scan.StandardJarScanner;
/**
* Standard implementation of the <b>Context</b> interface. Each
* child container must be a Wrapper implementation to process the
* requests directed to a particular servlet.
*
* @author Craig R. McClanahan
* @author Remy Maucherat
*/
public class StandardContext extends ContainerBase
implements Context, NotificationEmitter {
private static final Log log = LogFactory.getLog(StandardContext.class);
// ----------------------------------------------------------- Constructors
/**
* Create a new StandardContext component with the default basic Valve.
*/
public StandardContext() {
super();
pipeline.setBasic(new StandardContextValve());
broadcaster = new NotificationBroadcasterSupport();
// Set defaults
if (!Globals.STRICT_SERVLET_COMPLIANCE) {
// Strict servlet compliance requires all extension mapped servlets
// to be checked against welcome files
resourceOnlyServlets.add("jsp");
}
}
// ----------------------------------------------------- Class Variables
/**
* Array containing the safe characters set.
*/
protected static URLEncoder urlEncoder;
/**
* GMT timezone - all HTTP dates are on GMT
*/
static {
urlEncoder = new URLEncoder();
urlEncoder.addSafeCharacter('~');
urlEncoder.addSafeCharacter('-');
urlEncoder.addSafeCharacter('_');
urlEncoder.addSafeCharacter('.');
urlEncoder.addSafeCharacter('*');
urlEncoder.addSafeCharacter('/');
}
// ----------------------------------------------------- Instance Variables
/**
* Allow multipart/form-data requests to be parsed even when the
* target servlet doesn't specify @MultipartConfig or have a
* <multipart-config> element.
*/
protected boolean allowCasualMultipartParsing = false;
/**
* Control whether remaining request data will be read
* (swallowed) even if the request violates a data size constraint.
*/
private boolean swallowAbortedUploads = true;
/**
* The alternate deployment descriptor name.
*/
private String altDDName = null;
/**
*
没有合适的资源?快使用搜索试试~ 我知道了~
apache-tomcat-8.0.1-src.zip
共2876个文件
java:1918个
xml:190个
jsp:167个
需积分: 0 0 下载量 173 浏览量
2023-05-02
09:28:34
上传
评论
收藏 6.95MB ZIP 举报
温馨提示
apache-tomcat-8.0.1-src.zip
资源推荐
资源详情
资源评论
收起资源包目录
apache-tomcat-8.0.1-src.zip (2876个子文件)
catalina.bat 14KB
service.bat 6KB
tool-wrapper.bat 4KB
setclasspath.bat 3KB
digest.bat 2KB
configtest.bat 2KB
version.bat 2KB
startup.bat 2KB
shutdown.bat 2KB
cpappend.bat 1KB
side_left.bmp 337KB
header.bmp 10KB
eclipse.classpath 2KB
javax.websocket.ContainerProvider 47B
docs-stylesheet.css 6KB
tomcat.css 6KB
fonts.css 2KB
build.properties.default 12KB
build.properties.default 4KB
mvn.properties.default 2KB
leader-election-message-arrives.dia 6KB
leader-election-initiate-election.dia 3KB
web-app_2_3.dtd 31KB
XMLSchema.dtd 17KB
web-app_2_2.dtd 16KB
web-jsptaglibrary_1_2.dtd 13KB
mbeans-descriptors.dtd 10KB
datatypes.dtd 7KB
jspxml.dtd 6KB
web-jsptaglibrary_1_1.dtd 6KB
asf-logo.gif 7KB
asf-logo.gif 7KB
asf-logo.gif 7KB
asf-logo-wide.gif 6KB
BodyTagProtocol.gif 5KB
TagProtocol.gif 4KB
IterationTagProtocol.gif 4KB
tomcat-power.gif 2KB
VariableInfo-1.gif 2KB
tomcat.gif 2KB
tomcat.gif 2KB
tomcat.gif 2KB
tomcat.gif 2KB
tomcat.gif 1KB
execute.gif 1KB
execute.gif 1KB
return.gif 1KB
return.gif 1KB
read.gif 1KB
add.gif 1KB
add.gif 1KB
add.gif 1KB
update.gif 627B
update.gif 627B
update.gif 627B
design.gif 608B
design.gif 608B
design.gif 608B
printer.gif 438B
code.gif 394B
code.gif 394B
code.gif 394B
fix.gif 345B
fix.gif 345B
fix.gif 345B
code.gif 292B
code.gif 292B
docs.gif 261B
docs.gif 261B
docs.gif 261B
void.gif 43B
void.gif 43B
void.gif 43B
.gitignore 1KB
.gitignore 1KB
.gitignore 1KB
index.html.gz 135B
package.html 58KB
index.html 14KB
package.html 11KB
ELParser.html 9KB
index.html 7KB
welcome.bin.html 5KB
welcome.main.html 5KB
reqparams.html 5KB
package.html 4KB
package.html 4KB
package.html 4KB
reqinfo.html 4KB
package.html 4KB
sessions.html 3KB
package.html 3KB
cookies.html 3KB
helloworld.html 3KB
ColorGameBean.html 2KB
package.html 2KB
package.html 2KB
svgexample.html 2KB
reqheaders.html 2KB
index.html 2KB
共 2876 条
- 1
- 2
- 3
- 4
- 5
- 6
- 29
资源评论
Architect_Lee
- 粉丝: 89
- 资源: 8
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- Android源码新基线代码更新的方法
- 1_二级程序设计题(34).rar
- 二级程序调试题(填空27+改错7).docx
- HM2314-VB一款N-Channel沟道SOT23的MOSFET晶体管参数介绍与应用说明
- 基于深度学习的危险驾驶检测算法python源码+视频判断是否闭眼或者张开嘴哈欠和吸烟打电话等手势行为功能涵盖7类.zip
- Free-Fs 开源文件管理系统
- HM2314B-VB一款N-Channel沟道SOT23的MOSFET晶体管参数介绍与应用说明
- 毕业设计:Python高校学生学业预警系统(源码 + 数据库 + 说明文档)
- HM2312-VB一款N-Channel沟道SOT23的MOSFET晶体管参数介绍与应用说明
- 毕业设计:Python的在线自主评测系统(源码 + 数据库 + 说明文档)
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功