本文整理了Java中javax.xml.soap.SOAPHeader.addNamespaceDeclaration()
方法的一些代码示例,展示了SOAPHeader.addNamespaceDeclaration()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。SOAPHeader.addNamespaceDeclaration()
方法的具体详情如下:
包路径:javax.xml.soap.SOAPHeader
类名称:SOAPHeader
方法名:addNamespaceDeclaration
暂无
代码示例来源:origin: nl.psek.fitnesse/psek-fitnesse-fixtures-general
/**
* Add namespace to header.
*
* @param prefix the prefix
* @param namespaceUri the namespace uri
* @throws SOAPException the soap exception
*/
public void addNamespaceToHeader(String prefix, String namespaceUri) throws SOAPException {
this.soapMessage.getSOAPHeader().addNamespaceDeclaration(prefix, namespaceUri);
}
代码示例来源:origin: org.objectweb.celtix/celtix-rt
header.addNamespaceDeclaration(Names.WSRM_NAMESPACE_PREFIX,
Names.WSRM_NAMESPACE_NAME);
Marshaller marshaller = getJAXBContext().createMarshaller();
代码示例来源:origin: org.biomoby/taverna-biomoby
SOAPBody body = env.getBody();
header.addNamespaceDeclaration(mobyPrefix, MobyService.BIOMOBY_SERVICE_URI);
header.addNamespaceDeclaration(wsaPrefix, WSA_NS);
header.addNamespaceDeclaration(wsuPrefix, WSU_NS);
代码示例来源:origin: org.biomoby/taverna-biomoby
SOAPBody body = env.getBody();
header.addNamespaceDeclaration(mobyPrefix, MobyService.BIOMOBY_SERVICE_URI);
header.addNamespaceDeclaration(wsaPrefix, WSA_NS);
header.addNamespaceDeclaration(wsuPrefix, WSU_NS);
代码示例来源:origin: org.objectweb.celtix/celtix-rt
: env.addHeader();
discardMAPs(header);
header.addNamespaceDeclaration(Names.WSA_NAMESPACE_PREFIX,
maps.getNamespaceURI());
JAXBContext jaxbContext =
代码示例来源:origin: org.ow2.orchestra/orchestra-cxf-war
request = SOAPUtil.buildDocumentSOAPMessage(
"http://orchestra.ow2.org/cxf/test/wsaddressing/helloworldPT/submitRequest", part);
request.getSOAPHeader().addNamespaceDeclaration("wsa", XmlConstants.ADDRESSING_2005_REF_NAMESPACE);
final SOAPElement wsaAction = request.getSOAPHeader().addChildElement("Action", "wsa");
wsaAction.addTextNode("http://orchestra.ow2.org/cxf/test/wsaddressing/helloworldPT/submitRequest");
代码示例来源:origin: org.ow2.orchestra/orchestra-cxf-war
request = SOAPUtil.buildDocumentSOAPMessage(
"http://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequence", part);
request.getSOAPHeader().addNamespaceDeclaration("wsa", XmlConstants.ADDRESSING_2004_REF_NAMESPACE);
request.getSOAPHeader().addChildElement("To", "wsa").addTextNode(endpoint);
request.getSOAPHeader().addChildElement("ReplyTo", "wsa").addChildElement("Address", "wsa").addTextNode(WSRMTest.WS_ADD_2004_ANONYMOUS);
request = SOAPUtil.buildDocumentSOAPMessage(
"http://orchestra.ow2.org/cxf/test/wsrm/helloworldPT/submitRequest", part);
request.getSOAPHeader().addNamespaceDeclaration("wsa", XmlConstants.ADDRESSING_2004_REF_NAMESPACE);
request.getSOAPHeader().addNamespaceDeclaration("wsrm", WSRMTest.WS_RM_NS_URI);
request.getSOAPHeader().addChildElement("To", "wsa").addTextNode(endpoint);
request.getSOAPHeader().addChildElement("ReplyTo", "wsa").addChildElement("Address", "wsa").addTextNode(WSRMTest.WS_ADD_2004_ANONYMOUS);
request = SOAPUtil.buildDocumentSOAPMessage(
"http://orchestra.ow2.org/cxf/test/wsrm/helloworldPT/submitRequest", part);
request.getSOAPHeader().addNamespaceDeclaration("wsa", XmlConstants.ADDRESSING_2004_REF_NAMESPACE);
request.getSOAPHeader().addNamespaceDeclaration("wsrm", WSRMTest.WS_RM_NS_URI);
request.getSOAPHeader().addChildElement("To", "wsa").addTextNode(endpoint);
request.getSOAPHeader().addChildElement("ReplyTo", "wsa").addChildElement("Address", "wsa").addTextNode(WSRMTest.WS_ADD_2004_ANONYMOUS);
request = SOAPUtil.buildDocumentSOAPMessage(
"http://schemas.xmlsoap.org/ws/2005/02/rm/TerminateSequence", part);
request.getSOAPHeader().addNamespaceDeclaration("wsa", XmlConstants.ADDRESSING_2004_REF_NAMESPACE);
request.getSOAPHeader().addChildElement("To", "wsa").addTextNode(endpoint);
request.getSOAPHeader().addChildElement("ReplyTo", "wsa").addChildElement("Address", "wsa").addTextNode(WSRMTest.WS_ADD_2004_ANONYMOUS);
内容来源于网络,如有侵权,请联系作者删除!