org.apache.axis2.osgi.tx
Class HttpListener

java.lang.Object
  extended by org.apache.axis2.osgi.tx.HttpListener
All Implemented Interfaces:
TransportListener

public class HttpListener
extends Object
implements TransportListener

Default HttpListener that synch with the underlying listerner frameworks. This implemenation uses org.osgi.service.http.port property to find the port.

At the moment this will assume the underlying evn is Equinox. if the prior property is not set this will default to 80.


Field Summary
 
Fields inherited from interface org.apache.axis2.transport.TransportListener
HOST_ADDRESS, PARAM_PORT
 
Constructor Summary
HttpListener(org.osgi.framework.BundleContext context)
           
 
Method Summary
 void destroy()
           
 EndpointReference getEPRForService(String serviceName, String ip)
           
 EndpointReference[] getEPRsForService(String serviceName, String ip)
          Get the endpoint references for a given service.
 SessionContext getSessionContext(MessageContext messageContext)
          To get the sessionContext transport dependent manner.
 void init(ConfigurationContext configCtx, TransportInDescription transprtIn)
           
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpListener

public HttpListener(org.osgi.framework.BundleContext context)
Method Detail

init

public void init(ConfigurationContext configCtx,
                 TransportInDescription transprtIn)
          throws AxisFault
Specified by:
init in interface TransportListener
Throws:
AxisFault

start

public void start()
           throws AxisFault
Specified by:
start in interface TransportListener
Throws:
AxisFault

stop

public void stop()
          throws AxisFault
Specified by:
stop in interface TransportListener
Throws:
AxisFault

getEPRForService

public EndpointReference getEPRForService(String serviceName,
                                          String ip)
                                   throws AxisFault
Specified by:
getEPRForService in interface TransportListener
Throws:
AxisFault

getEPRsForService

public EndpointReference[] getEPRsForService(String serviceName,
                                             String ip)
                                      throws AxisFault
Description copied from interface: TransportListener
Get the endpoint references for a given service. These are the addresses that a client can use to send requests to the given service through this transport.

Specified by:
getEPRsForService in interface TransportListener
Parameters:
serviceName - TODO: this is actually not simply the service name!
ip - The host name or IP address of the local host. The implementation should use this information instead of InetAddress.getLocalHost(). The value of this parameter may be null, in which case the implementation should use Utils.getIpAddress( org.apache.axis2.engine.AxisConfiguration).
Returns:
an array of endpoint references for the given service
Throws:
AxisFault

getSessionContext

public SessionContext getSessionContext(MessageContext messageContext)
Description copied from interface: TransportListener
To get the sessionContext transport dependent manner. So that transport listener can return its own implementation of session managment

Specified by:
getSessionContext in interface TransportListener
Parameters:
messageContext - : MessageContext which has all the relavent data
Returns:
SessionContext

destroy

public void destroy()
Specified by:
destroy in interface TransportListener


Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.