Class Context.Wrapper

java.lang.Object
org.eclipse.jetty.server.Context.Wrapper
All Implemented Interfaces:
Executor, Context, org.eclipse.jetty.util.Attributes, org.eclipse.jetty.util.Decorator
Enclosing interface:
Context

public static class Context.Wrapper extends Object implements Context
  • Constructor Details

    • Wrapper

      public Wrapper(Context context)
  • Method Details

    • decorate

      public <T> T decorate(T o)
      Specified by:
      decorate in interface org.eclipse.jetty.util.Decorator
    • destroy

      public void destroy(Object o)
      Specified by:
      destroy in interface org.eclipse.jetty.util.Decorator
    • getContextPath

      public String getContextPath()
      Specified by:
      getContextPath in interface Context
      Returns:
      the encoded context path of this Context or null
    • getClassLoader

      public ClassLoader getClassLoader()
      Specified by:
      getClassLoader in interface Context
      Returns:
      the ClassLoader associated with this Context
    • getBaseResource

      public org.eclipse.jetty.util.resource.Resource getBaseResource()
      Specified by:
      getBaseResource in interface Context
      Returns:
      the base resource used to lookup other resources specified by the request URI path
    • getErrorHandler

      public Request.Handler getErrorHandler()
      Specified by:
      getErrorHandler in interface Context
      Returns:
      the error Request.Handler associated with this Context
    • getVirtualHosts

      public List<String> getVirtualHosts()
      Specified by:
      getVirtualHosts in interface Context
      Returns:
      a list of virtual host names associated with this Context
    • getMimeTypes

      public org.eclipse.jetty.http.MimeTypes getMimeTypes()
      Specified by:
      getMimeTypes in interface Context
      Returns:
      the mime types associated with this Context
    • execute

      public void execute(Runnable task)
      Description copied from interface: Context

      Executes the given task in a thread scoped to this Context.

      Specified by:
      execute in interface Context
      Specified by:
      execute in interface Executor
      Parameters:
      task - the task to run
      See Also:
    • removeAttribute

      public Object removeAttribute(String name)
      Specified by:
      removeAttribute in interface org.eclipse.jetty.util.Attributes
    • setAttribute

      public Object setAttribute(String name, Object attribute)
      Specified by:
      setAttribute in interface org.eclipse.jetty.util.Attributes
    • getAttribute

      public Object getAttribute(String name)
      Specified by:
      getAttribute in interface org.eclipse.jetty.util.Attributes
    • getAttributeNameSet

      public Set<String> getAttributeNameSet()
      Specified by:
      getAttributeNameSet in interface org.eclipse.jetty.util.Attributes
    • run

      public void run(Runnable task)
      Description copied from interface: Context

      Runs the given task in the current thread scoped to this Context.

      Specified by:
      run in interface Context
      Parameters:
      task - the task to run
      See Also:
    • run

      public void run(Runnable task, Request request)
      Description copied from interface: Context

      Runs the given task in the current thread scoped to this Context and the given Request.

      Specified by:
      run in interface Context
      Parameters:
      task - the task to run
      request - the HTTP request to use in the scope
    • getTempDirectory

      public File getTempDirectory()
      Specified by:
      getTempDirectory in interface Context
      Returns:
      a non-null temporary directory, configured either for the context, the server or the JVM