IT. Expert System.

Java Enterprise Edition (EE)

HttpContext


javax.xml.ws.spi.http
Class HttpContext

java.lang.Object
  javax.xml.ws.spi.http.HttpContext
public abstract class HttpContext
extends java.lang.Object

HttpContext represents a mapping between the root URI path of a web service to a HttpHandler which is invoked to handle requests destined for that path on the associated container.

Container provides the implementation for this and it matches web service requests to corresponding HttpContext objects.

Since:
JAX-WS 2.2
Author:
Jitendra Kotamraju

Field Summary
protected  HttpHandler handler
           
 
Constructor Summary
HttpContext()
           
 
Method Summary
abstract  java.lang.Object getAttribute(java.lang.String name)
          Returns an attribute value for container's configuration and other data that can be used by jax-ws runtime.
abstract  java.util.Set<java.lang.String> getAttributeNames()
          Returns all attribute names for container's configuration and other data that can be used by jax-ws runtime.
abstract  java.lang.String getPath()
          Returns the path for this context.
 void setHandler(HttpHandler handler)
          JAX-WS runtime sets its handler during Endpoint#publish(HttpContext) to handle HTTP requests for this context.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

handler

protected HttpHandler handler
Constructor Detail

HttpContext

public HttpContext()
Method Detail

setHandler

public void setHandler(HttpHandler handler)
JAX-WS runtime sets its handler during Endpoint#publish(HttpContext) to handle HTTP requests for this context. Container or its extensions use this handler to process the requests.

Parameters:
handler - the handler to set for this context

getPath

public abstract java.lang.String getPath()
Returns the path for this context. This path uniquely identifies an endpoint inside an application and the path is relative to application's context path. Container should give this path based on how it matches request URIs to this HttpContext object.

For servlet container, this is typically a url-pattern for an endpoint.

Endpoint's address for this context can be computed as follows:

  HttpExchange exch = ...;
  String endpointAddress =
      exch.getScheme() + "://"
      + exch.getLocalAddress().getHostName()
      + ":" + exch.getLocalAddress().getPort()
      + exch.getContextPath() + getPath();
 

Returns:
this context's path

getAttribute

public abstract java.lang.Object getAttribute(java.lang.String name)
Returns an attribute value for container's configuration and other data that can be used by jax-ws runtime.

Parameters:
name - attribute name
Returns:
attribute value

getAttributeNames

public abstract java.util.Set<java.lang.String> getAttributeNames()
Returns all attribute names for container's configuration and other data that can be used by jax-ws runtime.

Returns:
set of all attribute names


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 1261 / . Delta: 0.04524 с