Examples of declareNamespace()


Examples of org.apache.axiom.om.OMElement.declareNamespace()

                        String qname = reader.getAttributeLocalName(i);
                        String value = reader.getAttributeValue(i);
                       
                        if (ns != null) {
                            child.addAttribute(qname, value, fac.createOMNamespace(ns, prefix));
                            child.declareNamespace(ns, prefix);
                        } else {
                            child.addAttribute(qname, value, null);
                        }
                    }
                    current = child;
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

                header.addAttribute(fac.createOMAttribute(
                    "name", nullNS,
                    (qName.getPrefix() != null && !"".equals(qName.getPrefix())
                        ? qName.getPrefix() + ":" : "") +
                    qName.getLocalPart()));
                header.declareNamespace(qName.getNamespaceURI(), qName.getPrefix());
            } else {
                header.addAttribute(fac.createOMAttribute(
                    "name", nullNS, qName.getLocalPart()));
            }
        }
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

            factory.createOMNamespace("urn:oasis:names:tc:SAML:2.0:protocol",
                                      "samlp");
        OMElement response =
            factory.createOMElement("Response", samlp, soapBody);
        OMNamespace saml =
            response.declareNamespace("urn:oasis:names:tc:SAML:2.0:assertion",
                                      "saml");

        response.addAttribute("ID", "foo1", null);
        response.addAttribute("Version", "2.0", null);
        response.addAttribute("IssueInstant", strCurrentDate, null);
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

  @SuppressWarnings("unchecked")
  public OMElement createCall(String sessionId, String methodPath, Object arg) {
    OMElement method = fac.createOMElement(CORE_CALL, mag);

    // Register XML namespaces in method
    method.declareNamespace(soapEnc);
    method.declareNamespace(soapXml);
    method.declareNamespace(xsi);
    method.declareNamespace(xsd);

    OMElement paramSession = fac.createOMElement(SESSION_ID, noNs);
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

  public OMElement createCall(String sessionId, String methodPath, Object arg) {
    OMElement method = fac.createOMElement(CORE_CALL, mag);

    // Register XML namespaces in method
    method.declareNamespace(soapEnc);
    method.declareNamespace(soapXml);
    method.declareNamespace(xsi);
    method.declareNamespace(xsd);

    OMElement paramSession = fac.createOMElement(SESSION_ID, noNs);
    paramSession.addChild(fac.createOMText(paramSession, sessionId));
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

    OMElement method = fac.createOMElement(CORE_CALL, mag);

    // Register XML namespaces in method
    method.declareNamespace(soapEnc);
    method.declareNamespace(soapXml);
    method.declareNamespace(xsi);
    method.declareNamespace(xsd);

    OMElement paramSession = fac.createOMElement(SESSION_ID, noNs);
    paramSession.addChild(fac.createOMText(paramSession, sessionId));
    method.addChild(paramSession);
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

    // Register XML namespaces in method
    method.declareNamespace(soapEnc);
    method.declareNamespace(soapXml);
    method.declareNamespace(xsi);
    method.declareNamespace(xsd);

    OMElement paramSession = fac.createOMElement(SESSION_ID, noNs);
    paramSession.addChild(fac.createOMText(paramSession, sessionId));
    method.addChild(paramSession);
View Full Code Here

Examples of org.apache.axiom.om.OMElement.declareNamespace()

            JMethod jmethod = method[i];

            if (jmethod.isPublic()) {
                OMElement operation = fac.createOMElement(OPERATION_LOCAL_NAME, wsdl);
                binding.addChild(operation);
                operation.declareNamespace(URI_WSDL12_SOAP, SOAP12_PREFIX);

                addExtensionElement(fac,
                                    operation,
                                    soap12,
                                    OPERATION_LOCAL_NAME,
View Full Code Here

Examples of org.apache.axiom.soap.SOAPEnvelope.declareNamespace()

    public SOAPEnvelope getEchoSoapEnvelope() {

        SOAPFactory omfactory = OMAbstractFactory.getSOAP11Factory();
        SOAPEnvelope reqEnv = omfactory.getDefaultEnvelope();

        reqEnv.declareNamespace("http://www.w3.org/2001/XMLSchema", "xsd");
        reqEnv.declareNamespace("http://soapinterop.org/", "tns");
        reqEnv.declareNamespace("http://soapinterop.org/xsd", "s");
        OMNamespace encNs =
                reqEnv.declareNamespace("http://schemas.xmlsoap.org/soap/encoding/", "SOAP-ENC");
        OMNamespace typeNs =
View Full Code Here

Examples of org.apache.axiom.soap.SOAPFault.declareNamespace()

                        prefix = prefix == null ? "" : prefix;
                        uri = uri == null || "" .equals(uri) ?
                                fault.getNamespace().getNamespaceURI() : uri;
                        // Make sure the prefix and uri are declared on the fault, and
                        // get the resulting prefix.
                        prefix = fault.declareNamespace(uri, prefix).getPrefix();
                        soapFaultCode = prefix + ":" + faultCodeQName.getLocalPart();
                        if(log.isDebugEnabled()){
                          log.debug("Altered soapFaultCode ="+soapFaultCode);
                        }
                    } else {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.