View Javadoc

1   // ========================================================================
2   // Copyright (c) 2004-2009 Mort Bay Consulting Pty. Ltd.
3   // ------------------------------------------------------------------------
4   // All rights reserved. This program and the accompanying materials
5   // are made available under the terms of the Eclipse Public License v1.0
6   // and Apache License v2.0 which accompanies this distribution.
7   // The Eclipse Public License is available at 
8   // http://www.eclipse.org/legal/epl-v10.html
9   // The Apache License v2.0 is available at
10  // http://www.opensource.org/licenses/apache2.0.php
11  // You may elect to redistribute this code under either of these licenses. 
12  // ========================================================================
13  
14  package org.eclipse.jetty.server;
15  
16  import javax.servlet.ServletContext;
17  import javax.servlet.ServletRequest;
18  import javax.servlet.ServletResponse;
19  
20  import org.eclipse.jetty.continuation.ContinuationListener;
21  
22  /* temporary interface in anticipation of servlet 3.0 */
23  public interface AsyncContext 
24  {
25      static final String ASYNC_REQUEST_URI = "javax.servlet.async.request_uri";
26      static final String ASYNC_CONTEXT_PATH = "javax.servlet.async.context_path";
27      static final String ASYNC_PATH_INFO = "javax.servlet.async.path_info";
28      static final String ASYNC_SERVLET_PATH = "javax.servlet.async.servlet_path";
29      static final String ASYNC_QUERY_STRING = "javax.servlet.async.query_string";
30  
31      public ServletRequest getRequest();
32      public ServletResponse getResponse();
33      public boolean hasOriginalRequestAndResponse();
34      public void dispatch();
35      public void dispatch(String path);
36      public void dispatch(ServletContext context, String path);
37      public void complete();
38      public void start(Runnable run);
39      public void setTimeout(long ms);
40      public void addContinuationListener(ContinuationListener listener);
41  }
42  
43