Module org.eclipse.jetty.server
Package org.eclipse.jetty.server.handler
Class ContextHandler.ScopedContext
java.lang.Object
org.eclipse.jetty.util.Attributes.Layer
org.eclipse.jetty.server.handler.ContextHandler.ScopedContext
- All Implemented Interfaces:
Executor,Context,org.eclipse.jetty.util.Attributes,org.eclipse.jetty.util.Decorator
- Enclosing class:
ContextHandler
public class ContextHandler.ScopedContext
extends org.eclipse.jetty.util.Attributes.Layer
implements Context
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.Attributes
org.eclipse.jetty.util.Attributes.Layer, org.eclipse.jetty.util.Attributes.Lazy, org.eclipse.jetty.util.Attributes.Mapped, org.eclipse.jetty.util.Attributes.Wrapper -
Field Summary
Fields inherited from interface org.eclipse.jetty.util.Attributes
NULL -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoid<T> Tdecorate(T o) voidvoidExecutes the given task in a thread scoped to this Context.org.eclipse.jetty.util.resource.Resource<H extends ContextHandler>
Hprotected org.eclipse.jetty.util.DecoratedObjectFactoryorg.eclipse.jetty.http.MimeTypesgetPathInContext(String canonicallyEncodedPath) Returns the URI path scoped to this Context.voidRuns the given task in the current thread scoped to this Context.voidRuns the given task in the current thread scoped to this Context and the given Request.<T> booleantoString()Methods inherited from class org.eclipse.jetty.util.Attributes.Layer
clearAttributes, equals, getAttribute, getAttributeNameSet, getPersistentAttributes, hashCode, removeAttribute, setAttributeMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.eclipse.jetty.util.Attributes
asAttributeMap, clearAttributes, getAttribute, getAttributeNameSet, removeAttribute, setAttribute
-
Constructor Details
-
ScopedContext
public ScopedContext()
-
-
Method Details
-
getContextHandler
-
getErrorHandler
- Specified by:
getErrorHandlerin interfaceContext- Returns:
- the error
Request.Handlerassociated with this Context
-
getContextPath
- Specified by:
getContextPathin interfaceContext- Returns:
- the encoded context path of this
Contextornull
-
getMimeTypes
public org.eclipse.jetty.http.MimeTypes getMimeTypes()- Specified by:
getMimeTypesin interfaceContext- Returns:
- the mime types associated with this Context
-
toString
-
getClassLoader
- Specified by:
getClassLoaderin interfaceContext- Returns:
- the
ClassLoaderassociated with this Context
-
getBaseResource
public org.eclipse.jetty.util.resource.Resource getBaseResource()- Specified by:
getBaseResourcein interfaceContext- Returns:
- the base resource used to lookup other resources specified by the request URI path
-
getTempDirectory
- Specified by:
getTempDirectoryin interfaceContext- Returns:
- a non-
nulltemporary directory, configured either for the context, the server or the JVM
-
getVirtualHosts
- Specified by:
getVirtualHostsin interfaceContext- Returns:
- a list of virtual host names associated with this Context
-
call
public void call(org.eclipse.jetty.util.thread.Invocable.Callable callable, Request request) throws Exception - Throws:
Exception
-
test
-
accept
-
run
Description copied from interface:ContextRuns the given task in the current thread scoped to this Context.
-
run
Description copied from interface:ContextRuns the given task in the current thread scoped to this Context and the given Request.
-
execute
Description copied from interface:ContextExecutes the given task in a thread scoped to this Context.
-
getDecoratedObjectFactory
protected org.eclipse.jetty.util.DecoratedObjectFactory getDecoratedObjectFactory() -
decorate
public <T> T decorate(T o) - Specified by:
decoratein interfaceorg.eclipse.jetty.util.Decorator
-
destroy
- Specified by:
destroyin interfaceorg.eclipse.jetty.util.Decorator
-
getPathInContext
Description copied from interface:ContextReturns the URI path scoped to this Context.
- Specified by:
getPathInContextin interfaceContext- Parameters:
canonicallyEncodedPath- a full URI path that should be canonically encoded as perURIUtil.canonicalPath(String)- Returns:
- the URI path scoped to this Context, or
nullif the full path does not match this Context. The empty string is returned if the full path is exactly the context path. - See Also:
-