use of org.apache.cxf.binding.soap.saaj.SAAJInInterceptor in project ddf by codice.
the class SamlProtocol method parseSoapMessage.
public static SOAPPart parseSoapMessage(String samlRequest) throws XMLStreamException {
XMLStreamReader xmlStreamReader = xmlInputFactory.createXMLStreamReader(new StringReader(samlRequest));
SoapMessage soapMessage = new SoapMessage(Soap11.getInstance());
SAAJInInterceptor.SAAJPreInInterceptor preInInterceptor = new SAAJInInterceptor.SAAJPreInInterceptor();
soapMessage.setContent(XMLStreamReader.class, xmlStreamReader);
preInInterceptor.handleMessage(soapMessage);
SAAJInInterceptor inInterceptor = new SAAJInInterceptor();
inInterceptor.handleMessage(soapMessage);
return ((SOAPPart) soapMessage.getContent(Node.class));
}
Aggregations