Home » xml-commons-external-1.4.01-src » javax » xml » rpc » handler » [javadoc | source]
public interface: Handler [javadoc | source]

All Known Implementing Classes:

This interface is required to be implemented by a SOAP message handler. The handleRequest, handleResponse and handleFault methods for a SOAP message handler get access to the SOAPMessage from the SOAPMessageContext. The implementation of these methods can modify the SOAPMessage including the headers and body elements.
Method from javax.xml.rpc.handler.Handler Summary:
destroy,   getHeaders,   handleFault,   handleRequest,   handleResponse,   init
Method from javax.xml.rpc.handler.Handler Detail:
 public  void destroy() throws JAXRPCException
    The destroy method indicates the end of lifecycle for a Handler instance. The Handler implementation class should release its resources and perform cleanup in the implementation of the destroy method.
 public QName[] getHeaders()
    Gets the header blocks processed by this Handler instance.
 public boolean handleFault(MessageContext msgContext)
    The handleFault method processes the SOAP faults based on the SOAP message processing model.
 public boolean handleRequest(MessageContext msgContext) throws JAXRPCException, SOAPFaultException
    The handleRequest method processes the request message.
 public boolean handleResponse(MessageContext msgContext)
    The handleResponse method processes the response SOAP message.
 public  void init(HandlerInfo config) throws JAXRPCException
    The init method enables the Handler instance to initialize itself. The init method passes the handler configuration as a HandlerInfo instance. The HandlerInfo is used to configure the Handler (for example: setup access to an external resource or service) during the initialization. In the init method, the Handler class may get access to any resources (for example; access to a logging service or database) and maintain these as part of its instance variables. Note that these instance variables must not have any state specific to the SOAP message processing performed in the various handle method.