in cxf/cxf-binding-nmr/src/main/java/org/apache/servicemix/cxf/binding/nmr/interceptors/NMRFaultInInterceptor.java [48:70]
public void handleMessage(NMRMessage message) throws Fault {
XMLStreamReader xsr = message.getContent(XMLStreamReader.class);
DepthXMLStreamReader reader = new DepthXMLStreamReader(xsr);
try {
if (!StaxUtils.toNextElement(reader)) {
throw new Fault(new org.apache.cxf.common.i18n.Message("ILLEGAL_JBIFAULT_FORMAT", BUNDLE));
}
Fault fault = new NMRFault(new org.apache.cxf.common.i18n.Message(NMRFault.NMR_FAULT_STRING,
(ResourceBundle) null));
if (StaxUtils.toNextElement(reader)) {
// handling detail
Element detail = StaxUtils.read(new FragmentStreamReader(reader)).getDocumentElement();
fault.setDetail(detail);
}
message.setContent(Exception.class, fault);
} catch (XMLStreamException xse) {
throw new Fault(new org.apache.cxf.common.i18n.Message("STAX_READ_EXC", BUNDLE));
}
}