public abstract class HttpContext extends Object
HttpHandler被调用来处理目的地为相关的容器上的路径的请求。 
       Container为此提供了实现,并将Web服务请求与相应的HttpContext对象相匹配。
| Modifier and Type | Field and Description | 
|---|---|
| protected HttpHandler | handler | 
| Constructor and Description | 
|---|
| HttpContext() | 
| Modifier and Type | Method and Description | 
|---|---|
| abstract Object | getAttribute(String name)
              返回容器配置的属性值和jax-ws运行时可以使用的其他数据。 
             | 
| abstract Set<String> | getAttributeNames()
              返回容器配置的所有属性名称和jax-ws运行时可以使用的其他数据。 
             | 
| abstract String | getPath()
              返回此上下文的路径。 
             | 
| void | setHandler(HttpHandler handler)
              JAX-WS运行时在 
              Endpoint.publish(HttpContext)中设置其处理程序来处理此上下文的HTTP请求。 | 
protected HttpHandler handler
public void setHandler(HttpHandler handler)
Endpoint.publish(HttpContext)中设置其处理程序来处理此上下文的HTTP请求。 
           容器或其扩展名使用此处理程序来处理请求。 
          handler - 为此上下文设置的处理程序 
           public abstract String getPath()
对于servlet容器,这通常是端点的url模式。
该上下文的端点地址可以计算如下:
  HttpExchange exch = ...;
  String endpointAddress =
      exch.getScheme() + "://"
      + exch.getLocalAddress().getHostName()
      + ":" + exch.getLocalAddress().getPort()
      + exch.getContextPath() + getPath();  
          public abstract Object getAttribute(String name)
name - 属性名称 
            Submit a bug or feature 
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
 Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.