1
我正在寫一個處理程序,實現:如何獲得SOAP方法JAX-WS CXF處理器
SOAPHandler<SOAPMessageContext>
我只想做一個特定的SOAP調用的東西,但它看起來像處理程序被連接到整個Web服務,而不是一個特定的方法。
那麼,如何檢查在我的handleMessage代碼中調用了什麼方法?
感謝
我正在寫一個處理程序,實現:如何獲得SOAP方法JAX-WS CXF處理器
SOAPHandler<SOAPMessageContext>
我只想做一個特定的SOAP調用的東西,但它看起來像處理程序被連接到整個Web服務,而不是一個特定的方法。
那麼,如何檢查在我的handleMessage代碼中調用了什麼方法?
感謝
OK看起來像我找到了一種方法,不知道這是否是最好的方法,但它應該工作:
SOAPMessage message = smc.getMessage();
SOAPBody body = message.getSOAPBody();
//Then grabbing the first child node of the body and checking its name:
Iterator<Node> nodes = body.getChildElements();
// get the first one
if (n.getNodeName().equals("The node name for the particular operation")) {
// then we have it
}