org.codehaus.xfire.service.binding
Class ServiceInvocationHandler

java.lang.Object
  extended by org.codehaus.xfire.handler.AbstractHandler
      extended by org.codehaus.xfire.service.binding.ServiceInvocationHandler
All Implemented Interfaces:
Handler

public class ServiceInvocationHandler
extends AbstractHandler

This class is responsible for taking the parameters on the InMessage, invoking the service, then creating an OutMessage.

Author:
Dan Diephouse

Field Summary
 
Fields inherited from interface org.codehaus.xfire.handler.Handler
ROLE
 
Constructor Summary
ServiceInvocationHandler()
           
 
Method Summary
protected  void execute(Runnable runnable, Service service, OperationInfo operation)
          Run the Runnable which executes our service.
protected  Object[] fillInHolders(MessageContext context, OperationInfo opInfo, MessageInfo inMsg, MessageInfo outMsg, MessagePartContainer headerMsg, MessagePartContainer outHeaderMsg, List params)
          Looks for holders, instantiates them, then inserts them into the parameters.
 void invoke(MessageContext context)
          Invoke a handler.
static Object readHeaders(MessageContext context, MessagePartContainer headerMsg, Object[] paramArray)
           
protected  void sendMessage(MessageContext context, Object[] params, OperationInfo operation, Invoker invoker)
           
static void writeHeaders(MessageContext context, Object responseValue)
           
 
Methods inherited from class org.codehaus.xfire.handler.AbstractHandler
after, before, getAfter, getBefore, getPhase, getRoles, getUnderstoodHeaders, handleFault, setAfter, setBefore, setPhase
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServiceInvocationHandler

public ServiceInvocationHandler()
Method Detail

invoke

public void invoke(MessageContext context)
            throws Exception
Description copied from interface: Handler
Invoke a handler. If a fault occurs it will be handled via the handleFault method.

Throws:
Exception

execute

protected void execute(Runnable runnable,
                       Service service,
                       OperationInfo operation)
Run the Runnable which executes our service.

Parameters:
runnable -
service -
operation -

readHeaders

public static Object readHeaders(MessageContext context,
                                 MessagePartContainer headerMsg,
                                 Object[] paramArray)
                          throws XFireFault
Throws:
XFireFault

fillInHolders

protected Object[] fillInHolders(MessageContext context,
                                 OperationInfo opInfo,
                                 MessageInfo inMsg,
                                 MessageInfo outMsg,
                                 MessagePartContainer headerMsg,
                                 MessagePartContainer outHeaderMsg,
                                 List params)
                          throws XFireFault
Looks for holders, instantiates them, then inserts them into the parameters.

Returns:
Throws:
XFireFault

sendMessage

protected void sendMessage(MessageContext context,
                           Object[] params,
                           OperationInfo operation,
                           Invoker invoker)
                    throws Exception
Parameters:
context -
params -
operation -
invoker -
Throws:
Exception

writeHeaders

public static void writeHeaders(MessageContext context,
                                Object responseValue)
                         throws XFireFault,
                                javax.xml.stream.XMLStreamException
Throws:
XFireFault
javax.xml.stream.XMLStreamException


Copyright © 2004-2013. All Rights Reserved.