如何在 JAX-WS 中更改 SOAP 请求前缀。我在句柄消息中更新了 setprofix 方法
SOAPMessage msgs = ctx.getMessage();
SOAPMessage sm = MessageFactory.newInstance(SOAPConstants.SOAP_1_2_PROTOCOL).createMessage();
sm.getSOAPPart().getEnvelope().setPrefix("soap");
sm.getSOAPPart().getEnvelope().removeNamespaceDeclaration("env");
sm.getSOAPHeader().setPrefix("soap");
sm.getSOAPBody().setPrefix("soap");*/
但我仍然收到相同的请求
<?xml version="1.0"?>
<S:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
我需要
<Soap:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
请帮忙