public class StandardContext extends ContainerBase implements Context, javax.servlet.ServletContext
| Modifier and Type | Class and Description |
|---|---|
static class |
StandardContext.RestrictedServletContextListener |
ContainerBase.ContainerBackgroundProcessor, ContainerBase.PrivilegedAddChild| Modifier and Type | Field and Description |
|---|---|
protected boolean |
allowLinking
Allow linking.
|
protected int |
cacheMaxSize
Cache max size in KB.
|
protected int |
cacheTTL
Cache TTL in ms.
|
protected boolean |
caseSensitive
Case sensitivity.
|
protected boolean |
caseSensitiveMapping |
protected ApplicationContext |
context
The ServletContext implementation associated with this Context.
|
protected ArrayList<javax.servlet.ServletContextListener> |
contextListeners
The list of ServletContextListeners
|
protected boolean |
directoryDeployed |
protected boolean |
directoryListing
Should we generate directory listings?
|
protected ConcurrentMap<String,FilterRegistrationImpl> |
filterRegisMap |
protected boolean |
isJsfApplication
Is the context contains the JSF servlet.
|
protected ConcurrentMap<String,ServletRegistrationImpl> |
servletRegisMap |
protected int |
servletReloadCheckSecs |
protected boolean |
showArchivedRealPathEnabled |
protected static URLEncoder |
urlEncoder
Array containing the safe characters set.
|
backgroundProcessorDelay, checkIfRequestIsSecure, children, controller, debug, domain, hasCustomPipeline, initialized, lifecycle, listeners, loader, log, logger, manager, name, notifyContainerListeners, oname, parent, parentClassLoader, pipeline, rb, readLock, realm, resources, started, support, writeLockRELOAD_EVENTADD_CHILD_EVENT, ADD_MAPPER_EVENT, ADD_VALVE_EVENT, REMOVE_CHILD_EVENT, REMOVE_MAPPER_EVENT, REMOVE_VALVE_EVENTAFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, INIT_EVENT, START_EVENT, STOP_EVENT| Constructor and Description |
|---|
StandardContext()
Create a new StandardContext component with the default basic Valve.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAlternateDocBase(String urlPattern,
String docBase)
Configures this context's alternate doc base mappings.
|
void |
addApplicationListener(String listener)
Adds the Listener with the given class name that is declared in the
deployment descriptor to the set of Listeners configured for this
application.
|
void |
addApplicationParameter(ApplicationParameter parameter)
Add a new application parameter for this application.
|
void |
addChild(Container child)
Adds the given child Container to this context.
|
protected void |
addChild(Container child,
boolean isProgrammatic,
boolean createRegistration)
Adds the given child (Servlet) to this context.
|
void |
addConstraint(SecurityConstraint constraint)
Add a security constraint to the set for this web application.
|
void |
addEjb(ContextEjb ejb)
Add an EJB resource reference for this web application.
|
void |
addEnvironment(ContextEnvironment environment)
Add an environment entry for this web application.
|
String |
addEnvironment(String envName,
String type)
Add an environment entry for this web application.
|
void |
addErrorPage(ErrorPage errorPage)
Add an error page for the specified error or Java exception.
|
javax.servlet.FilterRegistration.Dynamic |
addFilter(String filterName,
Class<? extends javax.servlet.Filter> filterClass)
Adds the filter with the given name and class type to this servlet
context.
|
javax.servlet.FilterRegistration.Dynamic |
addFilter(String filterName,
javax.servlet.Filter filter) |
javax.servlet.FilterRegistration.Dynamic |
addFilter(String filterName,
String className)
Adds the filter with the given name and class name to this servlet
context.
|
void |
addFilterDef(FilterDef filterDef)
Add a filter definition to this Context.
|
void |
addFilterDef(FilterDef filterDef,
boolean isProgrammatic,
boolean createRegistration)
Add a filter definition to this Context.
|
void |
addFilterMap(FilterMap filterMap)
Add a filter mapping to this Context.
|
void |
addFilterMap(FilterMap filterMap,
boolean isMatchAfter)
Add a filter mapping to this Context.
|
void |
addFilterMaps(FilterMaps filterMaps)
Add multiple filter mappings to this Context.
|
void |
addInstanceListener(InstanceListener listener) |
void |
addInstanceListener(String listener)
Add the classname of an InstanceListener to be added to each
Wrapper appended to this Context.
|
javax.servlet.ServletRegistration.Dynamic |
addJspFile(String servletName,
String jspFile) |
void |
addJspMapping(String pattern)
Add the given URL pattern as a jsp-property-group.
|
void |
addListener(Class<? extends EventListener> listenerClass)
Adds a listener of the given class type to this ServletContext.
|
void |
addListener(String className)
Adds the listener with the given class name to this ServletContext.
|
<T extends EventListener> |
addListener(T t)
Adds the given listener instance to this ServletContext.
|
void |
addLocaleEncodingMappingParameter(String locale,
String encoding)
Add a Locale Encoding Mapping (see Sec 5.4 of Servlet spec 2.4)
|
void |
addLocalEjb(ContextLocalEjb ejb)
Add a local EJB resource reference for this web application.
|
void |
addMessageDestination(MessageDestination md)
Add a message destination for this web application.
|
void |
addMessageDestinationRef(MessageDestinationRef mdr)
Add a message destination reference for this web application.
|
void |
addMimeMapping(String extension,
String mimeType)
Add a new MIME mapping, replacing any existing mapping for
the specified extension.
|
void |
addParameter(String name,
String value)
Add a new context initialization parameter.
|
void |
addResource(ContextResource resource)
Add a resource reference for this web application.
|
String |
addResource(String resourceName,
String type)
Add a resource reference for this web application.
|
void |
addResourceEnvRef(String name,
String type)
Add a resource environment reference for this web application.
|
void |
addResourceLink(ContextResourceLink resourceLink)
Add a resource link for this web application.
|
String |
addResourceLink(String resourceLinkName,
String global,
String name,
String type)
Add a resource link for this web application.
|
void |
addResourceParams(ResourceParams resourceParameters)
Add resource parameters for this web application.
|
void |
addRoleMapping(String role,
String link)
Add a security role reference for this web application.
|
void |
addSecurityRole(String role)
Add a new security role for this web application.
|
javax.servlet.ServletRegistration.Dynamic |
addServlet(String servletName,
Class<? extends javax.servlet.Servlet> servletClass) |
javax.servlet.ServletRegistration.Dynamic |
addServlet(String servletName,
javax.servlet.Servlet servlet) |
javax.servlet.ServletRegistration.Dynamic |
addServlet(String servletName,
javax.servlet.Servlet instance,
Map<String,String> initParams)
Adds the given servlet instance with the given name to this servlet
context and initializes it.
|
javax.servlet.ServletRegistration.Dynamic |
addServlet(String servletName,
javax.servlet.Servlet servlet,
Map<String,String> initParams,
String... urlPatterns)
Adds the given servlet instance with the given name and URL patterns
to this servlet context, and initializes it.
|
javax.servlet.ServletRegistration.Dynamic |
addServlet(String servletName,
String className) |
Set<String> |
addServletMapping(ServletMap servletMap)
Adds the given servlet mappings to this Context.
|
void |
addServletMapping(String pattern,
String name)
Adds the given servlet mapping to this Context, overriding any
existing mapping for the specified pattern.
|
Set<String> |
addServletMapping(String name,
String[] urlPatterns)
Adds the given servlet mappings to this Context.
|
void |
addServletMapping(String pattern,
String name,
boolean jspWildCard)
Adds the given servlet mapping to this Context, overriding any
existing mapping for the specified pattern.
|
void |
addWatchedResource(String name)
Add a new watched resource to the set recognized by this Context.
|
void |
addWelcomeFile(String name)
Add a new welcome file to the set recognized by this Context.
|
void |
addWrapperLifecycle(String listener)
Add the classname of a LifecycleListener to be added to each
Wrapper appended to this Context.
|
void |
addWrapperListener(String listener)
Add the classname of a ContainerListener to be added to each
Wrapper appended to this Context.
|
protected String |
adjustURLPattern(String urlPattern)
Adjust the URL pattern to begin with a leading slash, if appropriate
(i.e.
|
void |
alternateResourcesStart()
Starts this context's alternate doc base resources.
|
boolean |
alternateResourcesStop()
Stops this context's alternate doc base resources.
|
void |
backgroundProcess()
Execute a periodic task, such as reloading, etc.
|
protected void |
callServletContainerInitializers() |
protected void |
contextListenerStart()
Notifies all ServletContextListeners at their contextInitialized
method.
|
void |
create() |
protected ServletRegistrationImpl |
createDynamicServletRegistrationImpl(StandardWrapper wrapper) |
<T extends javax.servlet.Filter> |
createFilter(Class<T> clazz)
Instantiates the given Filter class and performs any required
resource injection into the new Filter instance before returning
it.
|
protected <T extends javax.servlet.Filter> |
createFilterInstance(Class<T> clazz)
Instantiates the given Filter class.
|
<T extends javax.servlet.http.HttpUpgradeHandler> |
createHttpUpgradeHandlerInstance(Class<T> clazz)
Instantiates the given HttpUpgradeHandler class.
|
<T extends EventListener> |
createListener(Class<T> clazz)
Instantiates the given EventListener class and performs any
required resource injection into the new EventListener instance
before returning it.
|
<T extends EventListener> |
createListenerInstance(Class<T> clazz)
Instantiates the given EventListener class.
|
void |
createLoader()
Creates a classloader for this context.
|
ObjectInputStream |
createObjectInputStream(InputStream is)
Creates an ObjectInputStream that provides special deserialization
logic for classes that are normally not serializable (such as
javax.naming.Context).
|
ObjectName |
createObjectName(ContextEnvironment environment)
Create an
ObjectName for ContextEnvironment object. |
ObjectName |
createObjectName(ContextResource resource)
Create an
ObjectName for ContextResource object. |
ObjectName |
createObjectName(ContextResourceLink resourceLink)
Create an
ObjectName for ContextResourceLink object. |
ObjectName |
createObjectName(String hostDomain,
ObjectName parentName) |
ObjectOutputStream |
createObjectOutputStream(OutputStream os)
Creates an ObjectOutputStream that provides special serialization
logic for classes that are normally not serializable (such as
javax.naming.Context).
|
<T extends javax.servlet.Servlet> |
createServlet(Class<T> clazz)
Instantiates the given Servlet class and performs any required
resource injection into the new Servlet instance before returning
it.
|
protected <T extends javax.servlet.Servlet> |
createServletInstance(Class<T> clazz)
Instantiates the given Servlet class.
|
protected ServletRegistrationImpl |
createServletRegistrationImpl(StandardWrapper wrapper) |
Wrapper |
createWrapper()
Factory method to create and return a new Wrapper instance, of
the Java implementation class appropriate for this Context
implementation.
|
void |
declareRoles(String... roleNames) |
void |
destroy()
Destroys this context by cleaning it up completely.
|
protected File |
engineBase()
Return a File object representing the base directory for the
entire servlet container (i.e.
|
boolean |
filterStart()
Configure and initialize the set of filters for this Context.
|
boolean |
filterStop()
Finalize and release the set of filters for this Context.
|
List<ApplicationParameter> |
findApplicationParameters()
Return the set of application parameters for this application.
|
ContextEjb |
findEjb(String name)
Return the EJB resource reference with the specified name, if any;
otherwise, return
null. |
ContextEjb[] |
findEjbs()
Return the defined EJB resource references for this application.
|
ContextEnvironment |
findEnvironment(String name)
Return the environment entry with the specified name, if any;
otherwise, return
null. |
ContextEnvironment[] |
findEnvironments()
Return the set of defined environment entries for this web
application.
|
ErrorPage |
findErrorPage(int errorCode)
Return the error page entry for the specified HTTP error code,
if any; otherwise return
null. |
ErrorPage |
findErrorPage(String exceptionType)
Return the error page entry for the specified Java exception type,
if any; otherwise return
null. |
javax.servlet.FilterConfig |
findFilterConfig(String name)
Find and return the initialized
FilterConfig for the
specified filter name, if any; otherwise return null. |
FilterDef |
findFilterDef(String filterName)
Return the filter definition for the specified filter name, if any;
otherwise return
null. |
FilterDef[] |
findFilterDefs()
Return the set of defined filters for this Context.
|
List<FilterMap> |
findFilterMaps()
Return the list of filter mappings for this Context.
|
List<String> |
findInstanceListeners()
Return the list of InstanceListener classes that will be added to
newly created Wrappers automatically.
|
ContextLocalEjb |
findLocalEjb(String name)
Return the local EJB resource reference with the specified name, if any;
otherwise, return
null. |
ContextLocalEjb[] |
findLocalEjbs()
Return the defined local EJB resource references for this application.
|
Context |
findMappingObject()
FIXME: Fooling introspection ...
|
MessageDestination |
findMessageDestination(String name)
Return the message destination with the specified name, if any;
otherwise, return
null. |
MessageDestinationRef |
findMessageDestinationRef(String name)
Return the message destination ref with the specified name, if any;
otherwise, return
null. |
MessageDestinationRef[] |
findMessageDestinationRefs()
Return the set of defined message destination refs for this web
application.
|
MessageDestination[] |
findMessageDestinations()
Return the set of defined message destinations for this web
application.
|
String |
findMimeMapping(String extension)
Return the MIME type to which the specified extension is mapped,
if any; otherwise return
null. |
String[] |
findMimeMappings()
Return the extensions for which MIME mappings are defined.
|
String |
findParameter(String name)
Return the value for the specified context initialization
parameter name, if any; otherwise return
null. |
String[] |
findParameters()
Return the names of all defined context initialization parameters
for this Context.
|
ContextResource |
findResource(String name)
Return the resource reference with the specified name, if any;
otherwise return
null. |
String |
findResourceEnvRef(String name)
Return the resource environment reference type for the specified
name, if any; otherwise return
null. |
String[] |
findResourceEnvRefs()
Return the set of resource environment reference names for this
web application.
|
ContextResourceLink |
findResourceLink(String name)
Return the resource link with the specified name, if any;
otherwise return
null. |
ContextResourceLink[] |
findResourceLinks()
Return the defined resource links for this application.
|
ContextResource[] |
findResources()
Return the defined resource references for this application.
|
String |
findRoleMapping(String role)
For the given security role (as used by an application), return the
corresponding role name (as defined by the underlying Realm) if there
is one.
|
String |
findServletMapping(String pattern)
Return the servlet name mapped by the specified pattern (if any);
otherwise return
null. |
String[] |
findServletMappings()
Return the patterns of all defined servlet mappings for this
Context.
|
DirContext |
findStaticResources()
Return the naming resources associated with this web application.
|
ErrorPage |
findStatusPage(int status)
Return the context-relative URI of the error page for the specified
HTTP status code, if any; otherwise return
null. |
int[] |
findStatusPages()
Return the set of HTTP status codes for which error pages have
been specified.
|
boolean |
findWelcomeFile(String name)
Return
true if the specified welcome file is defined
for this Context; otherwise return false. |
String[] |
findWelcomeFiles()
Return the set of welcome files defined for this Context.
|
List<String> |
findWrapperLifecycles()
Return the list of LifecycleListener classes that will be added to
newly created Wrappers automatically.
|
List<String> |
findWrapperListeners()
Return the list of ContainerListener classes that will be added to
newly created Wrappers automatically.
|
void |
fireRequestDestroyedEvent(javax.servlet.ServletRequest request)
Notifies all ServletRequestListener instances configured for this Context
of the requestDestroyed event.
|
void |
fireRequestInitializedEvent(javax.servlet.ServletRequest request)
Notifies all ServletRequestListener instances configured for this Context
of the requestInitialized event.
|
String |
getAdHocServletName(String path)
Returns the name of the ad-hoc servlet responsible for servicing the
given path.
|
boolean |
getAllowRelativeRedirect()
Return whether this context allows sendRedirect() to redirect
to a relative URL.
|
String |
getAltDDName()
Return the alternate Deployment Descriptor name.
|
ArrayList<org.glassfish.grizzly.http.server.util.AlternateDocBase> |
getAlternateDocBases()
Gets this context's configured alternate doc bases.
|
boolean |
getAntiJARLocking()
Return the antiJARLocking flag for this Context.
|
List<EventListener> |
getApplicationEventListeners() |
Object |
getAttribute(String name)
Return the value of the specified context attribute, if any;
otherwise return
null. |
Enumeration<String> |
getAttributeNames()
Return an enumeration of the names of the context attributes
associated with this context.
|
Auditor[] |
getAuditors()
Get Auditors associated with this context, if any.
|
Authenticator |
getAuthenticator()
Gets the Authenticator of this Context.
|
boolean |
getAvailable()
Return the application available flag for this Context.
|
int |
getCacheMaxSize()
Return the maximum size of the cache in KB.
|
int |
getCacheTTL()
Get cache TTL.
|
CharsetMapper |
getCharsetMapper()
Return the Locale to character set mapper for this Context.
|
String |
getCharsetMapperClass()
Return the Locale to character set mapper class for this Context.
|
ClassLoader |
getClassLoader()
Gets the class loader of the web application represented by this
ServletContext.
|
String |
getCompilerClasspath()
Return the compiler classpath.
|
String |
getConfigFile()
Return the path to a file to save this Context information.
|
boolean |
getConfigured()
Return the "correctly configured" flag for this Context.
|
List<SecurityConstraint> |
getConstraints()
Gets the security constraints defined for this web application.
|
javax.servlet.ServletContext |
getContext(String uri)
Return a
ServletContext object that corresponds to a
specified URI on the server. |
String |
getContextPath()
Returns the context path of the web application.
|
boolean |
getCookies()
Return the "use cookies for session ids" flag.
|
boolean |
getCrossContext()
Return the "allow crossing servlet contexts" flag.
|
protected String |
getDefaultConfigFile()
Given a context path, get the config file name.
|
ErrorPage |
getDefaultErrorPage()
Gets the default error page of this context.
|
Set<javax.servlet.SessionTrackingMode> |
getDefaultSessionTrackingModes()
Gets the session tracking modes that are supported by default for this
ServletContext.
|
String |
getDefaultWebXml() |
boolean |
getDelegate()
Return the "follow standard delegation model" flag used to configure
our ClassLoader.
|
String |
getDisplayName()
Return the display name of this web application.
|
boolean |
getDistributable()
Return the distributable flag for this web application.
|
String |
getDocBase()
Return the document root for this Context.
|
int |
getEffectiveMajorVersion() |
int |
getEffectiveMinorVersion() |
Set<javax.servlet.SessionTrackingMode> |
getEffectiveSessionTrackingModes()
Gets the session tracking modes that are in effect for this
ServletContext.
|
String |
getEncodedPath()
Return the URL encoded context path, using UTF-8.
|
String |
getEngineName() |
String[] |
getEnvironments()
Return the MBean Names of the set of defined environment entries for
this web application
|
javax.servlet.FilterRegistration |
getFilterRegistration(String filterName)
Gets the FilterRegistration corresponding to the filter with the
given filterName.
|
Map<String,? extends javax.servlet.FilterRegistration> |
getFilterRegistrations()
Gets a Map of the FilterRegistration objects corresponding to all
currently registered filters.
|
String |
getHostname() |
String |
getInfo()
Return descriptive information about this Container implementation and
the corresponding version number, in the format
<description>/<version>. |
String |
getInitParameter(String name)
Return the value of the specified initialization parameter, or
null if this parameter does not exist. |
Enumeration<String> |
getInitParameterNames()
Return the names of the context's initialization parameters, or an
empty enumeration if the context has no initialization parameters.
|
String |
getJ2EEApplication() |
String |
getJ2EEServer() |
javax.servlet.descriptor.JspConfigDescriptor |
getJspConfigDescriptor()
Gets the
<jsp-config> related configuration
that was aggregated over the web.xml and
web-fragment.xml resources of the web application
represented by this ServletContext. |
String |
getJvmRoute() |
LoginConfig |
getLoginConfig()
Return the login configuration descriptor for this web application.
|
int |
getMajorVersion()
Return the major version of the Java Servlet API that we implement.
|
int |
getManagerChecksFrequency()
Return the frequency of manager checks.
|
org.glassfish.grizzly.http.server.util.Mapper |
getMapper()
Get the mapper associated with the context.
|
String |
getMimeType(String file)
Return the MIME type of the specified file, or
null if
the MIME type cannot be determined. |
int |
getMinorVersion()
Return the minor version of the Java Servlet API that we implement.
|
javax.servlet.RequestDispatcher |
getNamedDispatcher(String name)
Return a
RequestDispatcher object that acts as a
wrapper for the named servlet. |
String |
getNamingContextName()
Get naming context full name.
|
NamingResources |
getNamingResources()
Return the naming resources associated with this web application.
|
String |
getOriginalDocBase()
Gets the original document root for this Context, which can be an
absolute pathname, a relative pathname, or a URL.
|
boolean |
getOverride()
Return the DefaultContext override flag for this web application.
|
ObjectName |
getParentName()
Gets the name of the parent container
|
String |
getPath()
Return the context path for this Context.
|
boolean |
getPaused() |
boolean |
getPrivileged()
Return the privileged flag for this web application.
|
String |
getPublicId()
Return the public identifier of the deployment descriptor DTD that is
currently being parsed.
|
String |
getRealPath(String path)
Return the real path corresponding to the given virtual path, or
null if the container was unable to perform the
translation |
boolean |
getReloadable()
Return the reloadable flag for this web application.
|
String |
getRequestCharacterEncoding() |
javax.servlet.RequestDispatcher |
getRequestDispatcher(String path)
Return a
RequestDispatcher instance that acts as a
wrapper for the resource at the given path. |
URL |
getResource(String path)
Return the URL to the resource that is mapped to a specified path.
|
InputStream |
getResourceAsStream(String path)
Return the requested resource as an
InputStream. |
String[] |
getResourceLinks()
Return the MBean Names of all the defined resource links for this
application
|
String[] |
getResourceNames()
Return the MBean Names of all the defined resource references for this
application.
|
Set<String> |
getResourcePaths(String path)
Return a Set containing the resource paths of resources member of the
specified collection.
|
String |
getResponseCharacterEncoding() |
boolean |
getReuseSessionID()
Return the "reuse session IDs when creating sessions" flag
|
String |
getServerInfo()
Return the name and version of the servlet container.
|
javax.servlet.Servlet |
getServlet(String name)
Deprecated.
|
javax.servlet.ServletContext |
getServletContext()
Return the servlet context for which this Context is a facade.
|
String |
getServletContextName()
Return the display name of this web application.
|
Collection<String> |
getServletNameFilterMappings(String filterName)
Gets the current servlet name mappings of the Filter with
the given name.
|
Enumeration<String> |
getServletNames()
Deprecated.
|
javax.servlet.ServletRegistration |
getServletRegistration(String servletName)
Gets the ServletRegistration corresponding to the servlet with the
given servletName.
|
Map<String,? extends javax.servlet.ServletRegistration> |
getServletRegistrations()
Gets a Map of the ServletRegistration objects corresponding to all
currently registered servlets.
|
Enumeration<javax.servlet.Servlet> |
getServlets()
Deprecated.
|
javax.servlet.SessionCookieConfig |
getSessionCookieConfig()
Gets the session tracking cookie configuration of this
ServletContext.
|
String |
getSessionCookieName()
Gets the name that will be assigned to any session tracking
cookies created on behalf of this context
|
List<javax.servlet.http.HttpSessionListener> |
getSessionListeners() |
String |
getSessionParameterName() |
int |
getSessionTimeout()
Return the default session timeout (in minutes) for this
web application.
|
long |
getStartTimeMillis()
Gets the time this context was started.
|
long |
getStartupTime()
Gets the time (in milliseconds) it took to start this context.
|
int |
getState()
Returns the state of the server.
|
DirContext |
getStaticResources()
Return the naming resources associated with this web application.
|
boolean |
getTldNamespaceAware()
Get the server.xml
|
long |
getTldScanTime() |
boolean |
getTldValidation()
Get the server.xml
|
protected org.glassfish.hk2.classmodel.reflect.Types |
getTypes() |
long |
getUniqueId() |
long |
getUnloadDelay()
Return the value of the unloadDelay flag.
|
boolean |
getUnpackWAR()
Unpack WAR flag accessor.
|
Collection<String> |
getUrlPatternFilterMappings(String filterName)
Gets the current URL pattern mappings of the Filter with the given
name.
|
String |
getVirtualServerName() |
List<String> |
getWatchedResources()
Gets the watched resources defined for this web application.
|
String[] |
getWelcomeFiles()
Return the naming resources associated with this web application.
|
String |
getWorkDir()
Return the work directory for this Context.
|
String |
getWorkPath()
Get the absolute path to the work dir.
|
boolean |
getXmlNamespaceAware()
Get the server.xml
|
boolean |
getXmlValidation()
Get the server.xml
|
boolean |
hasAdHocPaths()
Indicates whether this web module contains any ad-hoc paths.
|
boolean |
hasConstraints()
Checks whether this web application has any security constraints
defined.
|
boolean |
hasFilter(javax.servlet.Filter filter)
Checks whether this context contains the given Filter instance
|
boolean |
hasSecurityRole(String role)
Checks if the given security role is defined for this application.
|
boolean |
hasServlet(javax.servlet.Servlet servlet)
Checks whether this context contains the given Servlet instance
|
boolean |
hasWatchedResources()
Checks whether this web application has any watched resources
defined.
|
void |
init()
Init method, part of the MBean lifecycle.
|
boolean |
isAllowLinking()
Is linking allowed.
|
boolean |
isCachingAllowed()
Is caching allowed ?
|
boolean |
isCaseSensitive()
Is case sensitive ?
|
boolean |
isCaseSensitiveMapping()
Are filters and security constraints mapped in a case sensitive manner?
|
boolean |
isDirectoryListing()
Checks whether directory listings are enabled or disabled on this
Context.
|
boolean |
isEmbedded() |
boolean |
isEnableURLRewriting()
Checks whether the rewriting of URLs with the jsessionids of
HTTP sessions belonging to this context is enabled or not.
|
boolean |
isEventProvider()
???
|
boolean |
isFilesystemBased() |
boolean |
isJsfApplication()
Scan the parent when searching for TLD listeners.
|
boolean |
isReload() |
boolean |
isReplaceWelcomeFiles()
Return the "replace welcome files" property.
|
boolean |
isSecurePagesWithPragma()
Returns the value of the securePagesWithPragma property.
|
protected boolean |
isServlet22()
Are we processing a version 2.2 deployment descriptor?
|
boolean |
isSessionTimeoutOveridden()
Is the session timeout (in minutes) for this
web application over-ridden from the default
HERCULES:add
|
protected boolean |
isStandalone() |
boolean |
isStatisticsProvider()
???MBean stats? unused
|
boolean |
isUseMyFaces() |
boolean |
isUseNaming()
Returns true if the internal naming support is used.
|
protected EventListener |
loadListener(ClassLoader loader,
String listenerClassName)
Loads and instantiates the listener with the specified classname.
|
void |
loadOnStartup(Container[] children)
Load and initialize all servlets marked "load on startup" in the
web application deployment descriptor.
|
void |
log(Exception exception,
String message)
Writes the specified exception and message to a servlet log file.
|
void |
log(String message)
Writes the specified message to a servlet log file.
|
void |
log(String message,
Throwable throwable)
Writes the specified message and exception to a servlet log file.
|
protected void |
managerStart()
Starts the session manager of this Context.
|
protected void |
managerStop()
Stops the session manager of this Context.
|
void |
reload()
Reload this web application, if reloading is supported.
|
void |
removeApplicationParameter(String name)
Remove the application parameter with the specified name from
the set for this application.
|
void |
removeAttribute(String name)
Remove the context attribute with the specified name, if any.
|
void |
removeChild(Container child)
Removes the given child container.
|
void |
removeConstraints()
Removes any security constraints from this web application.
|
void |
removeEjb(String name)
Remove any EJB resource reference with the specified name.
|
void |
removeEnvironment(String name)
Remove any environment entry with the specified name.
|
void |
removeErrorPages()
Removes any error page declarations.
|
void |
removeFilterDef(FilterDef filterDef)
Remove the specified filter definition from this Context, if it exists;
otherwise, no action is taken.
|
void |
removeFilterMaps()
Removes any filter mappings from this Context.
|
void |
removeInstanceListener(String listener)
Remove a class name from the list of InstanceListener classes that
will be added to newly created Wrappers.
|
void |
removeLocalEjb(String name)
Remove any local EJB resource reference with the specified name.
|
void |
removeMessageDestination(String name)
Remove any message destination with the specified name.
|
void |
removeMessageDestinationRef(String name)
Remove any message destination ref with the specified name.
|
void |
removeMimeMapping(String extension)
Remove the MIME mapping for the specified extension, if it exists;
otherwise, no action is taken.
|
void |
removeParameter(String name)
Remove the context initialization parameter with the specified
name, if it exists; otherwise, no action is taken.
|
protected void |
removePatternFromServlet(Wrapper wrapper,
String pattern)
This method is overridden in web-glue to also remove the given
mapping from the deployment backend's WebBundleDescriptor.
|
void |
removeResource(String resourceName)
Remove any resource reference with the specified name.
|
void |
removeResourceEnvRef(String name)
Remove any resource environment reference with the specified name.
|
void |
removeResourceLink(String link)
Remove any resource link with the specified name.
|
void |
removeRoleMapping(String role)
Remove any security role reference for the specified name
|
void |
removeSecurityRoles()
Removes any security roles defined for this application.
|
void |
removeServletMapping(String pattern)
Remove any servlet mapping for the specified pattern, if it exists;
otherwise, no action is taken.
|
void |
removeWatchedResources()
Clears any watched resources defined for this web application.
|
void |
removeWelcomeFiles() |
void |
removeWrapperLifecycles()
Removes any Wrapper lifecycle listeners from this Context
|
void |
removeWrapperListeners()
Removes any Wrapper listeners from this Context
|
boolean |
resourcesStart()
Allocate resources, including proxy.
|
boolean |
resourcesStop()
Deallocate resources and destroy proxy.
|
void |
restrictedSetPipeline(Pipeline pl)
Sets a new pipeline
|
void |
sendNotification(Notification notification) |
void |
sessionActivatedEndEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionActivatedStartEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionCreatedEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionDestroyedEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionExpiredEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionPassivatedEndEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionPassivatedStartEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionPersistedEndEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionPersistedStartEvent(javax.servlet.http.HttpSession session)
Trigger for monitoring
|
void |
sessionRejectedEvent(int maxSessions)
Trigger for monitoring
|
void |
setAllowLinking(boolean allowLinking)
Set allow linking.
|
void |
setAllowRelativeRedirect(boolean allowRelativeURLs)
Set whether this context allows sendRedirect() to redirect
to a relative URL.
|
void |
setAltDDName(String altDDName)
Set an alternate Deployment Descriptor name.
|
void |
setAntiJARLocking(boolean antiJARLocking)
Set the antiJARLocking feature for this Context.
|
void |
setAttribute(String name,
Object value)
Bind the specified value with the specified context attribute name,
replacing any existing value for that name.
|
void |
setAuditors(Auditor[] auditor)
Set the Auditors associated with this context.
|
void |
setAvailable(boolean available)
Set the application available flag for this Context.
|
void |
setCacheMaxSize(int cacheMaxSize)
Set the maximum size of the cache in KB.
|
void |
setCacheTTL(int cacheTTL)
Set cache TTL.
|
void |
setCachingAllowed(boolean cachingAllowed)
Set caching allowed flag.
|
void |
setCaseSensitive(boolean caseSensitive)
Set case sensitivity.
|
void |
setCaseSensitiveMapping(boolean caseSensitiveMap)
Set case sensitivity for filter and security constraint mappings.
|
void |
setCharsetMapper(CharsetMapper mapper)
Set the Locale to character set mapper for this Context.
|
void |
setCharsetMapperClass(String mapper)
Set the Locale to character set mapper class for this Context.
|
void |
setCompilerClasspath(String compilerClasspath)
Set the compiler classpath.
|
void |
setConfigFile(String configFile)
Set the path to a file to save this Context information.
|
void |
setConfigured(boolean configured)
Sets the "correctly configured" flag for this Context.
|
void |
setCookies(boolean cookies)
Set the "use cookies for session ids" flag.
|
void |
setCrossContext(boolean crossContext)
Sets the "allow crossing servlet contexts" flag.
|
void |
setDefaultWebXml(String defaultWebXml)
Set the location of the default web xml that will be used.
|
void |
setDelegate(boolean delegate)
Set the "follow standard delegation model" flag used to configure
our ClassLoader.
|
void |
setDirectoryListing(boolean directoryListing)
Enables or disables directory listings on this Context.
|
void |
setDisplayName(String displayName)
Set the display name of this web application.
|
void |
setDistributable(boolean distributable)
Set the distributable flag for this web application.
|
void |
setDocBase(String docBase)
Set the document root for this Context.
|
void |
setEffectiveMajorVersion(int effectiveMajorVersion) |
void |
setEffectiveMinorVersion(int effectiveMinorVersion) |
void |
setEmbedded(boolean isEmbedded) |
void |
setEnableURLRewriting(boolean enableURLRewriting)
Enables or disables the rewriting of URLs with the jsessionids of
HTTP sessions belonging to this context.
|
void |
setEngineName(String engineName) |
boolean |
setInitParameter(String name,
String value) |
void |
setJ2EEApplication(String j2EEApplication) |
void |
setJ2EEServer(String j2EEServer) |
void |
setJspConfigDescriptor(javax.servlet.descriptor.JspConfigDescriptor jspConfigDesc) |
void |
setJvmRoute(String jvmRoute) |
void |
setLoginConfig(LoginConfig config)
Set the login configuration descriptor for this web application.
|
void |
setManagerChecksFrequency(int managerChecksFrequency)
Set the manager checks frequency.
|
void |
setName(String name)
Set a name string (suitable for use by humans) that describes this
Container.
|
void |
setNamingResources(NamingResources namingResources)
Set the naming resources for this web application.
|
void |
setOrderedLibs(List<String> orderedLibs)
Sets the list of ordered libs, which will be used as the value of the
ServletContext attribute with name javax.servlet.context.orderedLibs
|
void |
setOriginalDocBase(String docBase)
Set the original document root for this Context, which can be an
absolute pathname, a relative pathname, or a URL.
|
void |
setOverride(boolean override)
Set the DefaultContext override flag for this web application.
|
void |
setPath(String path)
Set the context path for this Context.
|
void |
setPrivileged(boolean privileged)
Set the privileged flag for this web application.
|
void |
setPublicId(String publicId)
Set the public identifier of the deployment descriptor DTD that is
currently being parsed.
|
void |
setReload(boolean isReload) |
void |
setReloadable(boolean reloadable)
Set the reloadable flag for this web application.
|
void |
setReplaceWelcomeFiles(boolean replaceWelcomeFiles)
Set the "replace welcome files" property.
|
void |
setRequestCharacterEncoding(String encoding) |
void |
setResources(DirContext resources)
Set the resources DirContext object with which this Container is
associated.
|
void |
setResponseCharacterEncoding(String encoding) |
void |
setReuseSessionID(boolean reuse)
Set the "reuse session IDs when creating sessions" flag
|
void |
setSecurePagesWithPragma(boolean securePagesWithPragma)
Sets the securePagesWithPragma property of this Context.
|
void |
setServletContainerInitializerInterestList(Iterable<javax.servlet.ServletContainerInitializer> initializers) |
void |
setSessionTimeout(int timeout)
Set the default session timeout (in minutes) for this
web application.
|
void |
setSessionTrackingModes(Set<javax.servlet.SessionTrackingMode> sessionTrackingModes)
Sets the session tracking modes that are to become effective for this
ServletContext.
|
void |
setStartupTime(long startupTime) |
void |
setTldNamespaceAware(boolean tldNamespaceAware)
Set the namespace aware feature of the XML parser used when
parsing xml instances.
|
void |
setTldScanTime(long tldScanTime) |
void |
setTldValidation(boolean tldValidation)
Set the validation feature of the XML parser used when
parsing tlds files.
|
void |
setUnloadDelay(long unloadDelay)
Set the value of the unloadDelay flag, which represents the amount
of ms that the container will wait when unloading servlets.
|
void |
setUnpackWAR(boolean unpackWAR)
Unpack WAR flag mutator.
|
void |
setUseMyFaces(boolean useMyFaces) |
void |
setUseNaming(boolean useNaming)
Enables or disables naming.
|
void |
setWorkDir(String workDir)
Set the work directory for this Context.
|
void |
setXmlNamespaceAware(boolean webXmlNamespaceAware)
Set the namespace aware feature of the XML parser used when
parsing xml instances.
|
void |
setXmlValidation(boolean webXmlValidation)
Set the validation feature of the XML parser used when
parsing xml instances.
|
void |
start()
Start this Context component.
|
void |
startRecursive() |
void |
stop()
Stop this Context component.
|
void |
stop(boolean isShutdown)
Stop this Context component.
|
String |
toString()
Return a String representation of this component.
|
protected boolean |
validateURLPattern(String urlPattern)
Validate the syntax of a proposed
<url-pattern>
for conformance with specification requirements. |
addContainerListener, addLifecycleListener, addPropertyChangeListener, addValve, addValve, findChild, findChildren, findContainerListeners, findLifecycleListeners, fireContainerEvent, getBackgroundProcessorDelay, getBasic, getChildren, getContainerSuffix, getDebug, getDomain, getJmxName, getLoader, getLogger, getManager, getMappingObject, getName, getObjectName, getParent, getParentClassLoader, getPipeline, getRealm, getResources, getValveObjectNames, getValves, hasCustomPipeline, hasNonBasicValves, invoke, isCheckIfRequestIsSecure, logName, removeContainerListener, removeLifecycleListener, removeLifecycleListeners, removePropertyChangeListener, removeValve, setBackgroundProcessorDelay, setBasic, setCheckIfRequestIsSecure, setDebug, setDomain, setLoader, setLogger, setManager, setParent, setParentClassLoader, setRealm, startChildren, threadStart, threadStopclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddContainerListener, addPropertyChangeListener, findChild, findChildren, findContainerListeners, fireContainerEvent, getBackgroundProcessorDelay, getLoader, getLogger, getManager, getMappingObject, getName, getParent, getParentClassLoader, getPipeline, getRealm, getResources, hasCustomPipeline, invoke, isCheckIfRequestIsSecure, removeContainerListener, removePropertyChangeListener, setBackgroundProcessorDelay, setCheckIfRequestIsSecure, setLoader, setLogger, setManager, setParent, setParentClassLoader, setRealmprotected static final URLEncoder urlEncoder
protected ArrayList<javax.servlet.ServletContextListener> contextListeners
protected ApplicationContext context
protected boolean caseSensitive
protected boolean allowLinking
protected int cacheMaxSize
protected int cacheTTL
protected boolean caseSensitiveMapping
protected boolean isJsfApplication
protected ConcurrentMap<String,ServletRegistrationImpl> servletRegisMap
protected ConcurrentMap<String,FilterRegistrationImpl> filterRegisMap
protected boolean directoryDeployed
protected boolean showArchivedRealPathEnabled
protected int servletReloadCheckSecs
protected boolean directoryListing
public StandardContext()
public String getEncodedPath()
ContextgetEncodedPath in interface Contextpublic void setName(String name)
ContainerBasesetName in interface ContainersetName in class ContainerBasename - New name of this containerpublic boolean isCachingAllowed()
public void setCachingAllowed(boolean cachingAllowed)
public void setCaseSensitive(boolean caseSensitive)
public boolean isCaseSensitive()
public void setCaseSensitiveMapping(boolean caseSensitiveMap)
public boolean isCaseSensitiveMapping()
public void setAllowLinking(boolean allowLinking)
public boolean isAllowLinking()
public void setCacheTTL(int cacheTTL)
public int getCacheTTL()
public int getCacheMaxSize()
public void setCacheMaxSize(int cacheMaxSize)
public boolean getDelegate()
public void setDelegate(boolean delegate)
delegate - The new flagpublic boolean isUseNaming()
public void setUseNaming(boolean useNaming)
public boolean isFilesystemBased()
public List<EventListener> getApplicationEventListeners()
getApplicationEventListeners in interface Contextpublic List<javax.servlet.http.HttpSessionListener> getSessionListeners()
public boolean getAvailable()
getAvailable in interface Contextpublic void setAvailable(boolean available)
setAvailable in interface Contextavailable - The new application available flagpublic boolean getAntiJARLocking()
public void setAntiJARLocking(boolean antiJARLocking)
antiJARLocking - The new flag valuepublic CharsetMapper getCharsetMapper()
getCharsetMapper in interface Contextpublic void setCharsetMapper(CharsetMapper mapper)
setCharsetMapper in interface Contextmapper - The new mapperpublic String getRequestCharacterEncoding()
getRequestCharacterEncoding in interface javax.servlet.ServletContextpublic void setRequestCharacterEncoding(String encoding)
setRequestCharacterEncoding in interface javax.servlet.ServletContextpublic String getResponseCharacterEncoding()
getResponseCharacterEncoding in interface javax.servlet.ServletContextpublic void setResponseCharacterEncoding(String encoding)
setResponseCharacterEncoding in interface javax.servlet.ServletContextpublic String getConfigFile()
ContextgetConfigFile in interface Contextpublic void setConfigFile(String configFile)
setConfigFile in interface ContextconfigFile - The path to a file to save this Context informationpublic boolean getConfigured()
ContextgetConfigured in interface Contextpublic void setConfigured(boolean configured)
setConfigured in interface Contextconfigured - The new correctly configured flagpublic boolean getCookies()
ContextgetCookies in interface Contextpublic void setCookies(boolean cookies)
setCookies in interface Contextcookies - The new flagpublic boolean isEnableURLRewriting()
isEnableURLRewriting in interface Contextpublic void setEnableURLRewriting(boolean enableURLRewriting)
setEnableURLRewriting in interface ContextenableURLRewriting - true if the rewriting of URLs with the
jsessionids of HTTP sessions belonging to this context should be
enabled, false otherwisepublic boolean getCrossContext()
ContextgetCrossContext in interface Contextpublic void setCrossContext(boolean crossContext)
setCrossContext in interface ContextcrossContext - The new cross contexts flagpublic String getDefaultWebXml()
public void setDefaultWebXml(String defaultWebXml)
defaultWebXml - public long getStartupTime()
public void setStartupTime(long startupTime)
public long getTldScanTime()
public void setTldScanTime(long tldScanTime)
public String getDisplayName()
getDisplayName in interface Contextpublic String getAltDDName()
getAltDDName in interface Contextpublic void setAltDDName(String altDDName)
setAltDDName in interface Contextpublic String getCompilerClasspath()
public void setCompilerClasspath(String compilerClasspath)
public void setDisplayName(String displayName)
setDisplayName in interface ContextdisplayName - The new display namepublic boolean getDistributable()
getDistributable in interface Contextpublic void setDistributable(boolean distributable)
setDistributable in interface Contextdistributable - The new distributable flagpublic String getDocBase()
getDocBase in interface Contextpublic void setDocBase(String docBase)
setDocBase in interface ContextdocBase - The new document rootpublic void addAlternateDocBase(String urlPattern, String docBase)
urlPattern - docBase - public ArrayList<org.glassfish.grizzly.http.server.util.AlternateDocBase> getAlternateDocBases()
public int getManagerChecksFrequency()
public void setManagerChecksFrequency(int managerChecksFrequency)
managerChecksFrequency - the new manager checks frequencypublic String getInfo()
<description>/<version>.getInfo in interface ContainergetInfo in class ContainerBasepublic void setJvmRoute(String jvmRoute)
public String getJvmRoute()
public String getEngineName()
public void setEngineName(String engineName)
public String getJ2EEApplication()
public void setJ2EEApplication(String j2EEApplication)
public String getJ2EEServer()
public void setJ2EEServer(String j2EEServer)
public LoginConfig getLoginConfig()
getLoginConfig in interface Contextpublic void setLoginConfig(LoginConfig config)
setLoginConfig in interface Contextconfig - The new login configurationpublic org.glassfish.grizzly.http.server.util.Mapper getMapper()
public void restrictedSetPipeline(Pipeline pl)
public NamingResources getNamingResources()
getNamingResources in interface Contextpublic void setNamingResources(NamingResources namingResources)
setNamingResources in interface ContextnamingResources - The new naming resourcespublic String getPath()
public void setPath(String path)
IMPLEMENTATION NOTE: The context path is used as the "name" of a Context, because it must be unique.
public String getPublicId()
getPublicId in interface Contextpublic void setPublicId(String publicId)
setPublicId in interface ContextpublicId - The public identifierpublic boolean getReloadable()
getReloadable in interface Contextpublic boolean getOverride()
getOverride in interface Contextpublic String getOriginalDocBase()
public void setOriginalDocBase(String docBase)
docBase - The original document rootpublic boolean getPrivileged()
getPrivileged in interface Contextpublic void setPrivileged(boolean privileged)
setPrivileged in interface Contextprivileged - The new privileged flagpublic void setReloadable(boolean reloadable)
setReloadable in interface Contextreloadable - The new reloadable flagpublic void setOverride(boolean override)
setOverride in interface Contextoverride - The new override flagpublic boolean isJsfApplication()
isJsfApplication in interface Contextpublic boolean hasAdHocPaths()
hasAdHocPaths in interface Contextpublic String getAdHocServletName(String path)
getAdHocServletName in interface Contextpath - The path to servicepublic boolean isReplaceWelcomeFiles()
public void setReplaceWelcomeFiles(boolean replaceWelcomeFiles)
replaceWelcomeFiles - The new property valuepublic boolean isSecurePagesWithPragma()
isSecurePagesWithPragma in interface Contextpublic void setSecurePagesWithPragma(boolean securePagesWithPragma)
setSecurePagesWithPragma in interface ContextsecurePagesWithPragma - true if Pragma and Cache-Control headers
are to be set to "No-cache" if proxy caching has been disabled, false
otherwisepublic void setUseMyFaces(boolean useMyFaces)
public boolean isUseMyFaces()
public javax.servlet.ServletContext getServletContext()
getServletContext in interface Contextpublic int getSessionTimeout()
getSessionTimeout in interface javax.servlet.ServletContextgetSessionTimeout in interface Contextpublic boolean isSessionTimeoutOveridden()
public void setSessionTimeout(int timeout)
setSessionTimeout in interface javax.servlet.ServletContextsetSessionTimeout in interface Contexttimeout - The new default session timeoutpublic long getUnloadDelay()
public void setUnloadDelay(long unloadDelay)
unloadDelay - The new valuepublic boolean getUnpackWAR()
public void setUnpackWAR(boolean unpackWAR)
public void setResources(DirContext resources)
setResources in interface ContainersetResources in class ContainerBaseresources - The newly associated DirContextpublic boolean getReuseSessionID()
getReuseSessionID in interface Contextpublic void setReuseSessionID(boolean reuse)
setReuseSessionID in interface Contextreuse - The new value for the flagpublic boolean getAllowRelativeRedirect()
getAllowRelativeRedirect in interface Contextpublic void setAllowRelativeRedirect(boolean allowRelativeURLs)
setAllowRelativeRedirect in interface ContextallowRelativeURLs - The new value for this property.
The default value for this property is
'false'.public Auditor[] getAuditors()
getAuditors in interface Contextpublic void setAuditors(Auditor[] auditor)
setAuditors in interface Contextauditor - array of Auditor objectspublic void setReload(boolean isReload)
public boolean isReload()
public void setEmbedded(boolean isEmbedded)
public boolean isEmbedded()
public void setDirectoryListing(boolean directoryListing)
public boolean isDirectoryListing()
public String getCharsetMapperClass()
public void setCharsetMapperClass(String mapper)
mapper - The new mapper classpublic String getWorkPath()
public String getWorkDir()
public void setWorkDir(String workDir)
workDir - The new work directorypublic void addApplicationListener(String listener)
addApplicationListener in interface Contextlistener - the fully qualified class name of the Listenerpublic void addApplicationParameter(ApplicationParameter parameter)
addApplicationParameter in interface Contextparameter - The new application parameterpublic void addChild(Container child)
addChild in interface ContaineraddChild in class ContainerBasechild - the child Container to addIllegalArgumentException - if the given child Container is
not an instance of Wrapperprotected void addChild(Container child, boolean isProgrammatic, boolean createRegistration)
child - the child (Servlet) to addisProgrammatic - true if the given child (Servlet) is being
added via one of the programmatic interfaces, and false if it is
declared in the deployment descriptorcreateRegistration - true if a ServletRegistration needs to be
created for the given child, and false if a (preliminary)
ServletRegistration had already been created (which would be the
case if the Servlet had been declared in the deployment descriptor
without any servlet-class, and the servlet-class was later provided
via ServletContext#addServlet)IllegalArgumentException - if the given child Container is
not an instance of Wrapperprotected ServletRegistrationImpl createServletRegistrationImpl(StandardWrapper wrapper)
protected ServletRegistrationImpl createDynamicServletRegistrationImpl(StandardWrapper wrapper)
public void addConstraint(SecurityConstraint constraint)
addConstraint in interface Contextpublic void addEjb(ContextEjb ejb)
public void addEnvironment(ContextEnvironment environment)
addEnvironment in interface Contextenvironment - New environment entrypublic void addResourceParams(ResourceParams resourceParameters)
resourceParameters - New resource parameterspublic void addErrorPage(ErrorPage errorPage)
addErrorPage in interface ContexterrorPage - The error page definition to be addedpublic void addFilterDef(FilterDef filterDef)
addFilterDef in interface ContextfilterDef - The filter definition to be addedpublic void addFilterDef(FilterDef filterDef, boolean isProgrammatic, boolean createRegistration)
filterDef - The filter definition to be addedisProgrammatic - createRegistration - public void addFilterMaps(FilterMaps filterMaps)
filterMaps - The filter mappings to be addedIllegalArgumentException - if the specified filter name
does not match an existing filter definition, or the filter mapping
is malformedpublic void addFilterMap(FilterMap filterMap)
addFilterMap in interface ContextfilterMap - The filter mapping to be addedIllegalArgumentException - if the specified filter name
does not match an existing filter definition, or the filter mapping
is malformedpublic void addFilterMap(FilterMap filterMap, boolean isMatchAfter)
filterMap - The filter mapping to be addedisMatchAfter - true if the given filter mapping should be matched
against requests after any declared filter mappings of this servlet
context, and false if it is supposed to be matched before any declared
filter mappings of this servlet contextIllegalArgumentException - if the specified filter name
does not match an existing filter definition, or the filter mapping
is malformedpublic Collection<String> getServletNameFilterMappings(String filterName)
public Collection<String> getUrlPatternFilterMappings(String filterName)
public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, String className)
addFilter in interface javax.servlet.ServletContextpublic javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, javax.servlet.Filter filter)
addFilter in interface javax.servlet.ServletContextpublic boolean hasFilter(javax.servlet.Filter filter)
public javax.servlet.FilterRegistration.Dynamic addFilter(String filterName, Class<? extends javax.servlet.Filter> filterClass)
addFilter in interface javax.servlet.ServletContextpublic <T extends javax.servlet.Filter> T createFilter(Class<T> clazz) throws javax.servlet.ServletException
createFilter in interface javax.servlet.ServletContextjavax.servlet.ServletExceptionpublic javax.servlet.FilterRegistration getFilterRegistration(String filterName)
getFilterRegistration in interface javax.servlet.ServletContextpublic Map<String,? extends javax.servlet.FilterRegistration> getFilterRegistrations()
getFilterRegistrations in interface javax.servlet.ServletContextpublic javax.servlet.SessionCookieConfig getSessionCookieConfig()
getSessionCookieConfig in interface javax.servlet.ServletContextgetSessionCookieConfig in interface Contextpublic String getSessionCookieName()
getSessionCookieName in interface Contextpublic String getSessionParameterName()
getSessionParameterName in interface Contextpublic void setSessionTrackingModes(Set<javax.servlet.SessionTrackingMode> sessionTrackingModes)
setSessionTrackingModes in interface javax.servlet.ServletContextpublic Set<javax.servlet.SessionTrackingMode> getDefaultSessionTrackingModes()
getDefaultSessionTrackingModes in interface javax.servlet.ServletContextpublic Set<javax.servlet.SessionTrackingMode> getEffectiveSessionTrackingModes()
getEffectiveSessionTrackingModes in interface javax.servlet.ServletContextpublic void addListener(String className)
addListener in interface javax.servlet.ServletContextclassName - the fully qualified class name of the listenerpublic <T extends EventListener> void addListener(T t)
addListener in interface javax.servlet.ServletContextt - the listener to be addedpublic void addListener(Class<? extends EventListener> listenerClass)
addListener in interface javax.servlet.ServletContextpublic <T extends EventListener> T createListener(Class<T> clazz) throws javax.servlet.ServletException
createListener in interface javax.servlet.ServletContextjavax.servlet.ServletExceptionpublic void setJspConfigDescriptor(javax.servlet.descriptor.JspConfigDescriptor jspConfigDesc)
public javax.servlet.descriptor.JspConfigDescriptor getJspConfigDescriptor()
<jsp-config> related configuration
that was aggregated over the web.xml and
web-fragment.xml resources of the web application
represented by this ServletContext.getJspConfigDescriptor in interface javax.servlet.ServletContextpublic ClassLoader getClassLoader()
getClassLoader in interface javax.servlet.ServletContextpublic void declareRoles(String... roleNames)
declareRoles in interface javax.servlet.ServletContextpublic void setEffectiveMajorVersion(int effectiveMajorVersion)
public int getEffectiveMajorVersion()
getEffectiveMajorVersion in interface javax.servlet.ServletContextpublic void setEffectiveMinorVersion(int effectiveMinorVersion)
public int getEffectiveMinorVersion()
getEffectiveMinorVersion in interface javax.servlet.ServletContextpublic String getVirtualServerName()
getVirtualServerName in interface javax.servlet.ServletContextpublic void addInstanceListener(String listener)
addInstanceListener in interface Contextlistener - Java class name of an InstanceListener classpublic void addInstanceListener(InstanceListener listener)
public void addJspMapping(String pattern)
addJspMapping in interface Contextpattern - URL pattern to be mappedpublic void addLocaleEncodingMappingParameter(String locale, String encoding)
addLocaleEncodingMappingParameter in interface Contextlocale - locale to map an encoding forencoding - encoding to be used for a give localepublic void addLocalEjb(ContextLocalEjb ejb)
addLocalEjb in interface Contextejb - New EJB resource referencepublic void addMessageDestination(MessageDestination md)
md - New message destinationpublic void addMessageDestinationRef(MessageDestinationRef mdr)
mdr - New message destination referencepublic void addMimeMapping(String extension, String mimeType)
addMimeMapping in interface Contextextension - Filename extension being mappedmimeType - Corresponding MIME typepublic void addParameter(String name, String value)
addParameter in interface Contextname - Name of the new parametervalue - Value of the new parameterIllegalArgumentException - if the name or value is missing,
or if this context initialization parameter has already been
registeredpublic void addResource(ContextResource resource)
addResource in interface Contextresource - New resource referencepublic void addResourceEnvRef(String name, String type)
addResourceEnvRef in interface Contextname - The resource environment reference nametype - The resource environment reference typepublic void addResourceLink(ContextResourceLink resourceLink)
addResourceLink in interface ContextresourceLink - New resource linkpublic void addRoleMapping(String role, String link)
addRoleMapping in interface Contextrole - Security role used in the applicationlink - Actual security role to check forpublic void addSecurityRole(String role)
addSecurityRole in interface Contextrole - New security rolepublic Set<String> addServletMapping(ServletMap servletMap)
If any of the specified URL patterns are already mapped to a different Servlet, no updates will be performed.
servletMap - the Servlet mappings containing the Servlet name
and URL patternsIllegalArgumentException - if the specified servlet name
is not known to this Contextpublic Set<String> addServletMapping(String name, String[] urlPatterns)
If any of the specified URL patterns are already mapped to a different Servlet, no updates will be performed.
name - the Servlet nameurlPatterns - the URL patternsIllegalArgumentException - if the specified servlet name
is not known to this Contextpublic void addServletMapping(String pattern, String name)
addServletMapping in interface Contextpattern - URL pattern to be mappedname - Name of the corresponding servlet to executeIllegalArgumentException - if the specified servlet name
is not known to this Contextpublic void addServletMapping(String pattern, String name, boolean jspWildCard)
pattern - URL pattern to be mappedname - Name of the corresponding servlet to executejspWildCard - true if name identifies the JspServlet
and pattern contains a wildcard; false otherwiseIllegalArgumentException - if the specified servlet name
is not known to this Contextpublic javax.servlet.ServletRegistration.Dynamic addServlet(String servletName, String className)
addServlet in interface javax.servlet.ServletContextpublic javax.servlet.ServletRegistration.Dynamic addServlet(String servletName, javax.servlet.Servlet servlet)
addServlet in interface javax.servlet.ServletContextpublic javax.servlet.ServletRegistration.Dynamic addServlet(String servletName, Class<? extends javax.servlet.Servlet> servletClass)
addServlet in interface javax.servlet.ServletContextpublic javax.servlet.ServletRegistration.Dynamic addServlet(String servletName, javax.servlet.Servlet instance, Map<String,String> initParams)
In order to add any URL patterns that will be mapped to the given servlet, addServletMappings must be used. If this context has already been started, the URL patterns must be passed to addServlet instead.
addServlet in interface ContextservletName - the servlet nameinstance - the servlet instanceinitParams - Map containing the initialization parameters for
the servletjavax.servlet.ServletException - if the servlet fails to be initializedpublic javax.servlet.ServletRegistration.Dynamic addServlet(String servletName, javax.servlet.Servlet servlet, Map<String,String> initParams, String... urlPatterns)
addServlet in interface ContextservletName - the servlet nameservlet - the servlet instanceinitParams - Map containing the initialization parameters for
the servleturlPatterns - the URL patterns that will be mapped to the servletpublic javax.servlet.ServletRegistration.Dynamic addJspFile(String servletName, String jspFile)
addJspFile in interface javax.servlet.ServletContextprotected void removePatternFromServlet(Wrapper wrapper, String pattern)
public boolean hasServlet(javax.servlet.Servlet servlet)
servlet - public <T extends javax.servlet.Servlet> T createServlet(Class<T> clazz) throws javax.servlet.ServletException
createServlet in interface javax.servlet.ServletContextjavax.servlet.ServletExceptionpublic javax.servlet.ServletRegistration getServletRegistration(String servletName)
getServletRegistration in interface javax.servlet.ServletContextservletName - public Map<String,? extends javax.servlet.ServletRegistration> getServletRegistrations()
getServletRegistrations in interface javax.servlet.ServletContextpublic void addWatchedResource(String name)
addWatchedResource in interface Contextname - New watched resource file namepublic void addWelcomeFile(String name)
addWelcomeFile in interface Contextname - New welcome file namepublic void addWrapperLifecycle(String listener)
addWrapperLifecycle in interface Contextlistener - Java class name of a LifecycleListener classpublic void addWrapperListener(String listener)
addWrapperListener in interface Contextlistener - Java class name of a ContainerListener classpublic Wrapper createWrapper()
createWrapper in interface Contextpublic List<ApplicationParameter> findApplicationParameters()
findApplicationParameters in interface Contextpublic List<SecurityConstraint> getConstraints()
getConstraints in interface Contextpublic boolean hasConstraints()
hasConstraints in interface Contextpublic ContextEjb findEjb(String name)
null.public ContextEjb[] findEjbs()
public ContextEnvironment findEnvironment(String name)
null.findEnvironment in interface Contextname - Name of the desired environment entrypublic ContextEnvironment[] findEnvironments()
findEnvironments in interface Contextpublic ErrorPage findErrorPage(int errorCode)
null.findErrorPage in interface ContexterrorCode - Error code to look uppublic ErrorPage findErrorPage(String exceptionType)
null.findErrorPage in interface ContextexceptionType - Exception type to look uppublic ErrorPage getDefaultErrorPage()
A default error page is an error page that was declared without any exception-type and error-code.
getDefaultErrorPage in interface Contextpublic FilterDef findFilterDef(String filterName)
null.findFilterDef in interface ContextfilterName - Filter name to look uppublic FilterDef[] findFilterDefs()
findFilterDefs in interface Contextpublic List<FilterMap> findFilterMaps()
findFilterMaps in interface Contextpublic List<String> findInstanceListeners()
findInstanceListeners in interface Contextpublic ContextLocalEjb findLocalEjb(String name)
null.findLocalEjb in interface Contextname - Name of the desired EJB resource referencepublic ContextLocalEjb[] findLocalEjbs()
findLocalEjbs in interface Contextpublic Context findMappingObject()
public MessageDestination findMessageDestination(String name)
null.name - Name of the desired message destinationpublic MessageDestination[] findMessageDestinations()
public MessageDestinationRef findMessageDestinationRef(String name)
null.name - Name of the desired message destination refpublic MessageDestinationRef[] findMessageDestinationRefs()
public String findMimeMapping(String extension)
null.findMimeMapping in interface Contextextension - Extension to map to a MIME typepublic String[] findMimeMappings()
findMimeMappings in interface Contextpublic String findParameter(String name)
null.findParameter in interface Contextname - Name of the parameter to returnpublic String[] findParameters()
findParameters in interface Contextpublic ContextResource findResource(String name)
null.findResource in interface Contextname - Name of the desired resource referencepublic String findResourceEnvRef(String name)
null.findResourceEnvRef in interface Contextname - Name of the desired resource environment referencepublic String[] findResourceEnvRefs()
findResourceEnvRefs in interface Contextpublic ContextResourceLink findResourceLink(String name)
null.findResourceLink in interface Contextname - Name of the desired resource linkpublic ContextResourceLink[] findResourceLinks()
findResourceLinks in interface Contextpublic ContextResource[] findResources()
findResources in interface Contextpublic String findRoleMapping(String role)
findRoleMapping in interface Contextrole - Security role to mappublic boolean hasSecurityRole(String role)
hasSecurityRole in interface Contextrole - Security role to check forpublic void removeSecurityRoles()
removeSecurityRoles in interface Contextpublic String findServletMapping(String pattern)
null.findServletMapping in interface Contextpattern - Pattern for which a mapping is requestedpublic String[] findServletMappings()
findServletMappings in interface Contextpublic ErrorPage findStatusPage(int status)
null.findStatusPage in interface Contextstatus - HTTP status code to look uppublic int[] findStatusPages()
findStatusPages in interface Contextpublic boolean findWelcomeFile(String name)
true if the specified welcome file is defined
for this Context; otherwise return false.findWelcomeFile in interface Contextname - Welcome file to verifypublic List<String> getWatchedResources()
getWatchedResources in interface Contextpublic String[] findWelcomeFiles()
findWelcomeFiles in interface Contextpublic List<String> findWrapperLifecycles()
findWrapperLifecycles in interface Contextpublic List<String> findWrapperListeners()
findWrapperListeners in interface Contextpublic Authenticator getAuthenticator()
getAuthenticator in interface Contextpublic void reload()
IMPLEMENTATION NOTE: This method is designed to deal with reloads required by changes to classes in the underlying repositories of our class loader. It does not handle changes to the web application deployment descriptor. If that has occurred, you should stop this Context and create (and start) a new Context instance instead.
reload in interface ContextIllegalStateException - if the reloadable
property is set to false.public void removeApplicationParameter(String name)
removeApplicationParameter in interface Contextname - Name of the application parameter to removepublic void removeChild(Container child)
removeChild in interface ContainerremoveChild in class ContainerBasechild - the child container to be removedIllegalArgumentException - if the given child container is
not an implementation of Wrapperpublic void removeConstraints()
removeConstraints in interface Contextpublic void removeEjb(String name)
public void removeEnvironment(String name)
removeEnvironment in interface Contextname - Name of the environment entry to removepublic void removeErrorPages()
removeErrorPages in interface Contextpublic void removeFilterDef(FilterDef filterDef)
removeFilterDef in interface ContextfilterDef - Filter definition to be removedpublic void removeFilterMaps()
removeFilterMaps in interface Contextpublic void removeInstanceListener(String listener)
removeInstanceListener in interface Contextlistener - Class name of an InstanceListener class to be removedpublic void removeLocalEjb(String name)
removeLocalEjb in interface Contextname - Name of the EJB resource reference to removepublic void removeMessageDestination(String name)
name - Name of the message destination to removepublic void removeMessageDestinationRef(String name)
name - Name of the message destination ref to removepublic void removeMimeMapping(String extension)
removeMimeMapping in interface Contextextension - Extension to remove the mapping forpublic void removeParameter(String name)
removeParameter in interface Contextname - Name of the parameter to removepublic void removeResource(String resourceName)
removeResource in interface ContextresourceName - Name of the resource reference to removepublic void removeResourceEnvRef(String name)
removeResourceEnvRef in interface Contextname - Name of the resource environment reference to removepublic void removeResourceLink(String link)
removeResourceLink in interface Contextlink - Name of the resource link to removepublic void removeRoleMapping(String role)
removeRoleMapping in interface Contextrole - Security role (as used in the application) to removepublic void removeServletMapping(String pattern)
removeServletMapping in interface Contextpattern - URL pattern of the mapping to removepublic boolean hasWatchedResources()
hasWatchedResources in interface Contextpublic void removeWatchedResources()
removeWatchedResources in interface Contextpublic void removeWelcomeFiles()
removeWelcomeFiles in interface Contextpublic void removeWrapperLifecycles()
ContextremoveWrapperLifecycles in interface Contextpublic void removeWrapperListeners()
ContextremoveWrapperListeners in interface Contextpublic void fireRequestInitializedEvent(javax.servlet.ServletRequest request)
ContextfireRequestInitializedEvent in interface Contextpublic void fireRequestDestroyedEvent(javax.servlet.ServletRequest request)
ContextfireRequestDestroyedEvent in interface Contextpublic boolean filterStart()
true if all filter initialization completed
successfully, or false otherwise.public boolean filterStop()
true if all filter finalization completed
successfully, or false otherwise.public javax.servlet.FilterConfig findFilterConfig(String name)
FilterConfig for the
specified filter name, if any; otherwise return null.name - Name of the desired filterprotected void contextListenerStart()
protected EventListener loadListener(ClassLoader loader, String listenerClassName) throws Exception
loader - the classloader to uselistenerClassName - the fully qualified classname to instantiateException - if the specified classname fails to be loaded or
instantiatedpublic boolean resourcesStart()
true if initialization was successfull,
or false otherwise.public void alternateResourcesStart()
throws LifecycleException
LifecycleExceptionpublic boolean resourcesStop()
public boolean alternateResourcesStop()
public void loadOnStartup(Container[] children) throws LifecycleException
children - Array of wrappers for all currently defined
servlets (including those not declared load on startup)LifecycleExceptionprotected void managerStart()
throws LifecycleException
LifecycleExceptionprotected void managerStop()
throws LifecycleException
LifecycleExceptionpublic void start()
throws LifecycleException
start in interface Lifecyclestart in class ContainerBaseLifecycleException - if a startup error occursprotected org.glassfish.hk2.classmodel.reflect.Types getTypes()
protected boolean isStandalone()
protected void callServletContainerInitializers()
throws LifecycleException
LifecycleExceptionpublic void setServletContainerInitializerInterestList(Iterable<javax.servlet.ServletContainerInitializer> initializers)
public void createLoader()
public void stop()
throws LifecycleException
stop in interface Lifecyclestop in class ContainerBaseLifecycleException - if a shutdown error occurspublic void stop(boolean isShutdown)
throws LifecycleException
isShutdown - true if this Context is being stopped as part
of a domain shutdown (as opposed to an undeployment), and false otherwiseLifecycleException - if a shutdown error occurspublic void destroy()
throws Exception
destroy in class ContainerBaseExceptionpublic String toString()
public void backgroundProcess()
backgroundProcess in interface ContainerbackgroundProcess in class ContainerBaseprotected String adjustURLPattern(String urlPattern)
urlPattern - The URL pattern to be adjusted (if needed)
and returnedprotected boolean isServlet22()
protected File engineBase()
protected String getDefaultConfigFile()
public String getNamingContextName()
public boolean getPaused()
public String getHostname()
protected boolean validateURLPattern(String urlPattern)
<url-pattern>
for conformance with specification requirements.urlPattern - URL pattern to be validatedpublic String[] getEnvironments()
public String[] getResourceNames()
public String[] getResourceLinks()
public String addEnvironment(String envName, String type) throws MalformedObjectNameException
envName - New environment entry nameMalformedObjectNameExceptionpublic String addResource(String resourceName, String type) throws MalformedObjectNameException
resourceName - New resource reference nameMalformedObjectNameExceptionpublic String addResourceLink(String resourceLinkName, String global, String name, String type) throws MalformedObjectNameException
resourceLinkName - New resource link nameMalformedObjectNameExceptionpublic ObjectName createObjectName(String hostDomain, ObjectName parentName) throws MalformedObjectNameException
createObjectName in class ContainerBaseMalformedObjectNameExceptionpublic void sendNotification(Notification notification)
public void init()
throws Exception
ContainerBaseinit in class ContainerBaseExceptionpublic ObjectName getParentName() throws MalformedObjectNameException
ContainerBasegetParentName in class ContainerBaseMalformedObjectNameExceptionpublic ObjectName createObjectName(ContextEnvironment environment) throws MalformedObjectNameException
ObjectName for ContextEnvironment object.environment - The ContextEnvironment to be namedMalformedObjectNameException - if a name cannot be createdpublic ObjectName createObjectName(ContextResource resource) throws MalformedObjectNameException
ObjectName for ContextResource object.resource - The ContextResource to be namedMalformedObjectNameException - if a name cannot be createdpublic ObjectName createObjectName(ContextResourceLink resourceLink) throws MalformedObjectNameException
ObjectName for ContextResourceLink object.resourceLink - The ContextResourceLink to be namedMalformedObjectNameException - if a name cannot be createdpublic Object getAttribute(String name)
null.getAttribute in interface javax.servlet.ServletContextpublic Enumeration<String> getAttributeNames()
getAttributeNames in interface javax.servlet.ServletContextpublic String getContextPath()
getContextPath in interface javax.servlet.ServletContextpublic javax.servlet.ServletContext getContext(String uri)
ServletContext object that corresponds to a
specified URI on the server.getContext in interface javax.servlet.ServletContextpublic String getInitParameter(String name)
null if this parameter does not exist.getInitParameter in interface javax.servlet.ServletContextpublic Enumeration<String> getInitParameterNames()
getInitParameterNames in interface javax.servlet.ServletContextpublic boolean setInitParameter(String name, String value)
setInitParameter in interface javax.servlet.ServletContextpublic int getMajorVersion()
getMajorVersion in interface javax.servlet.ServletContextpublic int getMinorVersion()
getMinorVersion in interface javax.servlet.ServletContextpublic String getMimeType(String file)
null if
the MIME type cannot be determined.getMimeType in interface javax.servlet.ServletContextpublic javax.servlet.RequestDispatcher getNamedDispatcher(String name)
RequestDispatcher object that acts as a
wrapper for the named servlet.getNamedDispatcher in interface javax.servlet.ServletContextpublic String getServletContextName()
getServletContextName in interface javax.servlet.ServletContextpublic void removeAttribute(String name)
removeAttribute in interface javax.servlet.ServletContextpublic void setAttribute(String name, Object value)
setAttribute in interface javax.servlet.ServletContextpublic String getServerInfo()
getServerInfo in interface javax.servlet.ServletContextpublic String getRealPath(String path)
null if the container was unable to perform the
translationgetRealPath in interface javax.servlet.ServletContextpublic void log(String message)
log in interface javax.servlet.ServletContextlog in class ContainerBasemessage - Message to be loggedpublic void log(Exception exception, String message)
log in interface javax.servlet.ServletContextpublic void log(String message, Throwable throwable)
log in interface javax.servlet.ServletContextlog in class ContainerBasemessage - Message to be loggedthrowable - Related exception@Deprecated public javax.servlet.Servlet getServlet(String name)
getServlet in interface javax.servlet.ServletContext@Deprecated public Enumeration<String> getServletNames()
getServletNames in interface javax.servlet.ServletContext@Deprecated public Enumeration<javax.servlet.Servlet> getServlets()
getServlets in interface javax.servlet.ServletContextpublic InputStream getResourceAsStream(String path)
InputStream. The
path must be specified according to the rules described under
getResource. If no such resource can be identified,
return null.getResourceAsStream in interface javax.servlet.ServletContextpublic URL getResource(String path) throws MalformedURLException
getResource in interface javax.servlet.ServletContextMalformedURLExceptionpublic Set<String> getResourcePaths(String path)
getResourcePaths in interface javax.servlet.ServletContextpublic javax.servlet.RequestDispatcher getRequestDispatcher(String path)
RequestDispatcher instance that acts as a
wrapper for the resource at the given path. The path must begin
with a "/" and is interpreted as relative to the current context root.getRequestDispatcher in interface javax.servlet.ServletContextpublic DirContext getStaticResources()
public DirContext findStaticResources()
public String[] getWelcomeFiles()
public void setXmlValidation(boolean webXmlValidation)
setXmlValidation in interface ContextwebXmlValidation - true to enable xml instance validationpublic boolean getXmlValidation()
getXmlValidation in interface Contextpublic boolean getXmlNamespaceAware()
getXmlNamespaceAware in interface Contextpublic void setXmlNamespaceAware(boolean webXmlNamespaceAware)
setXmlNamespaceAware in interface ContextwebXmlNamespaceAware - true to enable namespace awarenesspublic void setTldValidation(boolean tldValidation)
setTldValidation in interface ContexttldValidation - true to enable xml instance validationpublic boolean getTldValidation()
getTldValidation in interface Contextpublic boolean getTldNamespaceAware()
getTldNamespaceAware in interface Contextpublic void setTldNamespaceAware(boolean tldNamespaceAware)
setTldNamespaceAware in interface ContexttldNamespaceAware - true to enable namespace awarenesspublic void setOrderedLibs(List<String> orderedLibs)
public void startRecursive()
throws LifecycleException
LifecycleExceptionpublic int getState()
It will return 0, 1 3 or 4.
public ObjectInputStream createObjectInputStream(InputStream is) throws IOException
is - IOExceptionpublic ObjectOutputStream createObjectOutputStream(OutputStream os) throws IOException
os - IOExceptionpublic long getStartTimeMillis()
public boolean isEventProvider()
public boolean isStatisticsProvider()
public void sessionCreatedEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProviderpublic void sessionDestroyedEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionDestroyedEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionRejectedEvent(int maxSessions)
maxSessions - SessionStatsProvider.sessionRejectedEvent(int, java.lang.String, java.lang.String)public void sessionExpiredEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionExpiredEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionPersistedStartEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionPersistedStartEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionPersistedEndEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionPersistedEndEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionActivatedStartEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionActivatedStartEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionActivatedEndEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionActivatedEndEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionPassivatedStartEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionPassivatedStartEvent(java.lang.String, java.lang.String, java.lang.String)public void sessionPassivatedEndEvent(javax.servlet.http.HttpSession session)
session - SessionStatsProvider.sessionPassivatedEndEvent(java.lang.String, java.lang.String, java.lang.String)public long getUniqueId()
protected <T extends javax.servlet.Servlet> T createServletInstance(Class<T> clazz) throws Exception
Exceptionprotected <T extends javax.servlet.Filter> T createFilterInstance(Class<T> clazz) throws Exception
Exceptionpublic <T extends EventListener> T createListenerInstance(Class<T> clazz) throws Exception
ExceptionCopyright © 2019. All rights reserved.