log.debug("Enter: DebugHandler::invoke");
try {
Message msg = msgContext.getRequestMessage();
SOAPEnvelope message = (SOAPEnvelope)msg.getSOAPEnvelope();
SOAPHeaderElement header = message.
getHeaderByName(NS_URI_DEBUG, "Debug");
if (header != null) {
Integer i = ((Integer)header
.getValueAsType(Constants.XSD_INT));
if (i == null)
throw new AxisFault(Messages.getMessage("cantConvert03"));
int debugVal = i.intValue();
log.debug(Messages.getMessage("debugLevel00", "" + debugVal) );
//Debug.setDebugLevel(debugVal);
header.setProcessed(true);
}
}
catch( Exception e ) {
log.error( Messages.getMessage("exception00"), e );
throw AxisFault.makeFault(e);
}
log.debug("Exit: DebugHandler::invoke");