public static void traceException ( TraceComponent callersTrace , Throwable ex ) { if ( light_tc . isDebugEnabled ( ) || callersTrace . isDebugEnabled ( ) ) { // Find XA completion code if one exists, as this isn't in a normal dump String xaErrStr = null ; if ( ex instanceof XAException ) { XAException xaex = ( XAException ) ex ; xaErrStr = "XAExceptionErrorCode: " + xaex . errorCode ; } // Trace using the correct trace group if ( light_tc . isDebugEnabled ( ) ) { if ( xaErrStr != null ) SibTr . debug ( light_tc , xaErrStr ) ; SibTr . exception ( light_tc , ex ) ; } else { if ( xaErrStr != null ) SibTr . debug ( callersTrace , xaErrStr ) ; SibTr . exception ( callersTrace , ex ) ; } } }
Trace an exception .