org.codehaus.xfire.handler
Class CustomFaultHandler

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

public class CustomFaultHandler
extends AbstractHandler

Builds up a custom detail element from an exception.

Author:
Dan Diephouse

Field Summary
 
Fields inherited from interface org.codehaus.xfire.handler.Handler
ROLE
 
Constructor Summary
CustomFaultHandler()
           
 
Method Summary
protected  java.lang.Object getFaultBean(java.lang.Throwable cause, MessagePartInfo faultPart, MessageContext context)
           
 FaultInfo getFaultForClass(OperationInfo op, java.lang.Class class1)
          Find the correct Fault part for a particular exception.
protected  void handleFault(MessageContext context, XFireFault fault, java.lang.Throwable cause, MessagePartInfo faultPart)
           
 void invoke(MessageContext context)
          Invoke a handler.
 
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

CustomFaultHandler

public CustomFaultHandler()
Method Detail

invoke

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

Throws:
java.lang.Exception

handleFault

protected void handleFault(MessageContext context,
                           XFireFault fault,
                           java.lang.Throwable cause,
                           MessagePartInfo faultPart)
                    throws XFireFault
Throws:
XFireFault

getFaultBean

protected java.lang.Object getFaultBean(java.lang.Throwable cause,
                                        MessagePartInfo faultPart,
                                        MessageContext context)

getFaultForClass

public FaultInfo getFaultForClass(OperationInfo op,
                                  java.lang.Class class1)
Find the correct Fault part for a particular exception.

Parameters:
op -
class1 -
Returns:


Copyright © 2004-2010. All Rights Reserved.