org.apache.cxf.transport.http
Class JettyHTTPDestination

java.lang.Object
  extended by org.apache.cxf.transport.AbstractDestination
      extended by org.apache.cxf.transport.http.AbstractHTTPDestination
          extended by org.apache.cxf.transport.http.JettyHTTPDestination
All Implemented Interfaces:
org.apache.cxf.configuration.Configurable, org.apache.cxf.transport.Destination, org.apache.cxf.transport.Observable

public class JettyHTTPDestination
extends AbstractHTTPDestination


Nested Class Summary
protected  class JettyHTTPDestination.BackChannelConduit
          Backchannel conduit.
 
Nested classes/interfaces inherited from class org.apache.cxf.transport.AbstractDestination
org.apache.cxf.transport.AbstractDestination.AbstractBackChannelConduit
 
Field Summary
protected  ServerEngine alternateEngine
           
protected  ServerEngine engine
           
static java.lang.String HTTP_REQUEST
           
static java.lang.String HTTP_RESPONSE
           
 
Fields inherited from class org.apache.cxf.transport.http.AbstractHTTPDestination
authorization, bus, conduitInitiator, contextMatchStrategy, fixedParameterOrder, name, nurl, server, sslServer
 
Fields inherited from class org.apache.cxf.transport.AbstractDestination
endpointInfo, incomingObserver, reference
 
Constructor Summary
JettyHTTPDestination(org.apache.cxf.Bus b, org.apache.cxf.transport.ConduitInitiator ci, org.apache.cxf.service.model.EndpointInfo endpointInfo)
          Constructor, using Jetty server engine.
JettyHTTPDestination(org.apache.cxf.Bus b, org.apache.cxf.transport.ConduitInitiator ci, org.apache.cxf.service.model.EndpointInfo endpointInfo, ServerEngine eng)
          Constructor, allowing subsititution of server engine.
 
Method Summary
protected  void activate()
          Activate receipt of incoming messages.
protected  void copyRequestHeaders(org.apache.cxf.message.Message message, java.util.Map<java.lang.String,java.util.List<java.lang.String>> headers)
          Copy the request headers into the message.
protected  void copyResponseHeaders(org.apache.cxf.message.Message message, org.mortbay.http.HttpResponse response)
          Copy the response headers into the response.
protected  void deactivate()
          Deactivate receipt of incoming messages.
protected  void doService(org.mortbay.http.HttpRequest req, org.mortbay.http.HttpResponse resp)
           
protected  java.io.OutputStream flushHeaders(org.apache.cxf.message.Message outMessage)
           
protected  org.apache.cxf.transport.ConduitInitiator getConduitInitiator()
           
protected  org.apache.cxf.transport.Conduit getInbuiltBackChannel(org.apache.cxf.message.Message inMessage)
           
protected  java.util.logging.Logger getLogger()
           
protected  boolean markPartialResponse(org.apache.cxf.message.Message partialResponse, org.apache.cxf.ws.addressing.EndpointReferenceType decoupledTarget)
          Mark message as a partial message.
protected  void retrieveEngine()
          Post-configure retreival of server engine.
protected  void serviceRequest(org.mortbay.http.HttpRequest req, org.mortbay.http.HttpResponse resp)
           
 
Methods inherited from class org.apache.cxf.transport.http.AbstractHTTPDestination
getAddressValue, getAuthorization, getBeanName, getContextMatchStrategy, getServer, getSslServer, isFixedParameterOrder, isOneWay, setAuthorization, setContextMatchStrategy, setFixedParameterOrder, setHeaders, setServer, setSslServer, updateResponseHeaders
 
Methods inherited from class org.apache.cxf.transport.AbstractDestination
getAddress, getBackChannel, getMessageObserver, getTargetReference, setMessageObserver, shutdown
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HTTP_REQUEST

public static final java.lang.String HTTP_REQUEST

HTTP_RESPONSE

public static final java.lang.String HTTP_RESPONSE

engine

protected ServerEngine engine

alternateEngine

protected ServerEngine alternateEngine
Constructor Detail

JettyHTTPDestination

public JettyHTTPDestination(org.apache.cxf.Bus b,
                            org.apache.cxf.transport.ConduitInitiator ci,
                            org.apache.cxf.service.model.EndpointInfo endpointInfo)
                     throws java.io.IOException
Constructor, using Jetty server engine.

Parameters:
b - the associated Bus
ci - the associated conduit initiator
endpointInfo - the endpoint info of the destination
Throws:
java.io.IOException

JettyHTTPDestination

public JettyHTTPDestination(org.apache.cxf.Bus b,
                            org.apache.cxf.transport.ConduitInitiator ci,
                            org.apache.cxf.service.model.EndpointInfo endpointInfo,
                            ServerEngine eng)
                     throws java.io.IOException
Constructor, allowing subsititution of server engine.

Parameters:
b - the associated Bus
ci - the associated conduit initiator
endpointInfo - the endpoint info of the destination
eng - the server engine
Throws:
java.io.IOException
Method Detail

getLogger

protected java.util.logging.Logger getLogger()
Specified by:
getLogger in class org.apache.cxf.transport.AbstractDestination

retrieveEngine

protected void retrieveEngine()
Post-configure retreival of server engine.


activate

protected void activate()
Activate receipt of incoming messages.

Overrides:
activate in class org.apache.cxf.transport.AbstractDestination

deactivate

protected void deactivate()
Deactivate receipt of incoming messages.

Overrides:
deactivate in class org.apache.cxf.transport.AbstractDestination

getInbuiltBackChannel

protected org.apache.cxf.transport.Conduit getInbuiltBackChannel(org.apache.cxf.message.Message inMessage)
Specified by:
getInbuiltBackChannel in class org.apache.cxf.transport.AbstractDestination
Parameters:
inMessage - the incoming message
Returns:
the inbuilt backchannel

markPartialResponse

protected boolean markPartialResponse(org.apache.cxf.message.Message partialResponse,
                                      org.apache.cxf.ws.addressing.EndpointReferenceType decoupledTarget)
Mark message as a partial message.

Overrides:
markPartialResponse in class org.apache.cxf.transport.AbstractDestination
Parameters:
partialResponse - the partial response message
the - decoupled target
Returns:
true iff partial responses are supported

getConduitInitiator

protected org.apache.cxf.transport.ConduitInitiator getConduitInitiator()
Overrides:
getConduitInitiator in class org.apache.cxf.transport.AbstractDestination
Returns:
the associated conduit initiator

copyRequestHeaders

protected void copyRequestHeaders(org.apache.cxf.message.Message message,
                                  java.util.Map<java.lang.String,java.util.List<java.lang.String>> headers)
Copy the request headers into the message.

Specified by:
copyRequestHeaders in class AbstractHTTPDestination
Parameters:
message - the current message
headers - the current set of headers

copyResponseHeaders

protected void copyResponseHeaders(org.apache.cxf.message.Message message,
                                   org.mortbay.http.HttpResponse response)
Copy the response headers into the response.

Parameters:
message - the current message
headers - the current set of headers

doService

protected void doService(org.mortbay.http.HttpRequest req,
                         org.mortbay.http.HttpResponse resp)
                  throws java.io.IOException
Throws:
java.io.IOException

serviceRequest

protected void serviceRequest(org.mortbay.http.HttpRequest req,
                              org.mortbay.http.HttpResponse resp)
                       throws java.io.IOException
Throws:
java.io.IOException

flushHeaders

protected java.io.OutputStream flushHeaders(org.apache.cxf.message.Message outMessage)
                                     throws java.io.IOException
Throws:
java.io.IOException


Copyright © 2006-2007 Apache Software Foundation. All Rights Reserved.