Package org.apache.axiom.soap

Examples of org.apache.axiom.soap.SOAPFactory.createOMElement()


      data.setReason(SandeshaMessageHelper.getMessage(SandeshaMessageKeys.cannotAcceptMsgAsSequenceClosedFault));
      data.setType(Sandesha2Constants.SOAPFaults.FaultType.SEQUENCE_CLOSED);
     
      SOAPFactory factory = SOAPAbstractFactory.getSOAPFactory(SOAPVersion);
      String rmNamespaceValue = referenceRMMessage.getRMNamespaceValue();
      OMElement identifierElement = factory.createOMElement(Sandesha2Constants.WSRM_COMMON.IDENTIFIER,
          rmNamespaceValue, Sandesha2Constants.WSRM_COMMON.NS_PREFIX_RM);
      identifierElement.setText(sequenceID);
     
      data.setDetail(identifierElement);
View Full Code Here


      data.setCode(SOAP11Constants.FAULT_CODE_SENDER);
      data.setSubcode(SpecSpecificConstants.getFaultSubcode(rmMessageContext.getRMNamespaceValue(),
          Sandesha2Constants.SOAPFaults.FaultType.MESSAGE_NUMBER_ROLLOVER ));

      SOAPFactory factory = SOAPAbstractFactory.getSOAPFactory(SOAPVersion);
      OMElement identifierElement = factory.createOMElement(Sandesha2Constants.WSRM_COMMON.IDENTIFIER,
          rmMessageContext.getRMNamespaceValue(), Sandesha2Constants.WSRM_COMMON.NS_PREFIX_RM);
      identifierElement.setText(sequenceId);
     
      OMElement maxMsgNumber = factory.createOMElement(Sandesha2Constants.WSRM_COMMON.MAX_MSG_NUMBER,
          rmMessageContext.getRMNamespaceValue(), Sandesha2Constants.WSRM_COMMON.NS_PREFIX_RM);
View Full Code Here

      SOAPFactory factory = SOAPAbstractFactory.getSOAPFactory(SOAPVersion);
      OMElement identifierElement = factory.createOMElement(Sandesha2Constants.WSRM_COMMON.IDENTIFIER,
          rmMessageContext.getRMNamespaceValue(), Sandesha2Constants.WSRM_COMMON.NS_PREFIX_RM);
      identifierElement.setText(sequenceId);
     
      OMElement maxMsgNumber = factory.createOMElement(Sandesha2Constants.WSRM_COMMON.MAX_MSG_NUMBER,
          rmMessageContext.getRMNamespaceValue(), Sandesha2Constants.WSRM_COMMON.NS_PREFIX_RM);
      maxMsgNumber.setText(Long.toString(msgNo));
     
      data.setDetail(identifierElement);
      data.setDetail2(maxMsgNumber);
View Full Code Here

    public void testConvert1() {
        try {
            SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();
            SOAPEnvelope env = fac.getDefaultEnvelope();
            fac.createOMElement(new QName("http://test.org", "Test"), env.getBody());
            env.build();

            StAXSOAPModelBuilder doomBuilder = new StAXSOAPModelBuilder(env.getXMLStreamReader(),
                                                                        DOOMAbstractFactory.getSOAP11Factory(),
                                                                        SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI);
View Full Code Here

    public void testAddChild() {
        try {
            SOAPFactory fac = DOOMAbstractFactory.getSOAP11Factory();
            SOAPEnvelope env = fac.getDefaultEnvelope();
            fac.createOMElement(new QName("http://test.org", "Test"), env.getBody());
            env.build();

            SOAPFactory llomFac = DOOMAbstractFactory.getSOAP11Factory();
            OMElement elem = llomFac.createOMElement("newDomElement", null);
View Full Code Here

            SOAPEnvelope env = fac.getDefaultEnvelope();
            fac.createOMElement(new QName("http://test.org", "Test"), env.getBody());
            env.build();

            SOAPFactory llomFac = DOOMAbstractFactory.getSOAP11Factory();
            OMElement elem = llomFac.createOMElement("newDomElement", null);

            OMElement firstElement = env.getBody().getFirstElement();
            firstElement.addChild(elem);

            assertTrue("New DOM child missing",
View Full Code Here

        OMNamespace samlp =
            factory.createOMNamespace("urn:oasis:names:tc:SAML:2.0:protocol",
                                      "samlp");

        OMElement artifactResponse =
            factory.createOMElement("ArtifactResponse", samlp, soapBody);
        OMNamespace saml =
            artifactResponse.declareDefaultNamespace("urn:oasis:names:tc:SAML:2.0:assertion");
        artifactResponse.addAttribute("ID", "foo1", null);
        artifactResponse.addAttribute("Version", "2.0", null);
        artifactResponse.addAttribute("InResponseTo", "Unspecified", null);
View Full Code Here

                                      artifactRequest.getIssueInstant(), null);


        //namespace
        OMElement issuer =
            factory.createOMElement("Issuer", saml, artifactResponse);
        issuer.addAttribute("xmlns", "urn:oasis:names:tc:SAML:2.0:assertion",
                            null);
        issuer.setText(issuerName);

View Full Code Here

                            null);
        issuer.setText(issuerName);


        OMElement status =
            factory.createOMElement("Status", samlp, artifactResponse);
        OMElement statusCode =
            factory.createOMElement("StatusCode", samlp, status);
        statusCode.addAttribute("Value", buildStatus, null);

        if (buildStatus == SAML_STATUS_CODE_SUCCESS && userName != null) {
View Full Code Here


        OMElement status =
            factory.createOMElement("Status", samlp, artifactResponse);
        OMElement statusCode =
            factory.createOMElement("StatusCode", samlp, status);
        statusCode.addAttribute("Value", buildStatus, null);

        if (buildStatus == SAML_STATUS_CODE_SUCCESS && userName != null) {
            OMElement response =
                factory.createOMElement("Response", samlp, artifactResponse);
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.