Package javax.xml.soap

Examples of javax.xml.soap.SOAPBodyElement.addChildElement()


        Name bodyName = envelope.createName("echo");
        SOAPBodyElement bodyElement = body.addBodyElement(bodyName);

        Name name = envelope.createName("arg0");
        SOAPElement symbol = bodyElement.addChildElement(name);
        symbol.addTextNode("Hello");

        URLEndpoint endpoint = new URLEndpoint("http://localhost:8080/jws/FaultTest.jws");
        SOAPMessage response = con.call(message, endpoint);
        SOAPBody respBody = response.getSOAPPart().getEnvelope().getBody();
View Full Code Here


            /* Creates the body with the operation and its parameters */
            operationName = envelope.createName(opName, "", namespace);
            operation = body.addBodyElement(operationName);

            keyParamName = envelope.createName("AWSAccessKeyId");
            keyParam = operation.addChildElement(keyParamName);
            keyParam.addTextNode(properties.getProperty("AWSAccessKeyId"));
           
            reqParamName = envelope.createName("Request");
            reqParam = operation.addChildElement(reqParamName);
           
View Full Code Here

            keyParamName = envelope.createName("AWSAccessKeyId");
            keyParam = operation.addChildElement(keyParamName);
            keyParam.addTextNode(properties.getProperty("AWSAccessKeyId"));
           
            reqParamName = envelope.createName("Request");
            reqParam = operation.addChildElement(reqParamName);
           
            for(String auxName : paramsName)
            {
                paramName = envelope.createName(auxName);
                param = reqParam.addChildElement(paramName);
View Full Code Here

            /* Creates the body with the operation and its parameters */
            operationName = envelope.createName(opName, "", namespace);
            operation = body.addBodyElement(operationName);

            keyParamName = envelope.createName("AWSAccessKeyId");
            keyParam = operation.addChildElement(keyParamName);
            keyParam.addTextNode(properties.getProperty("AWSAccessKeyId"));
           
            reqParamName = envelope.createName("Request");
            reqParam = operation.addChildElement(reqParamName);
           
View Full Code Here

            keyParamName = envelope.createName("AWSAccessKeyId");
            keyParam = operation.addChildElement(keyParamName);
            keyParam.addTextNode(properties.getProperty("AWSAccessKeyId"));
           
            reqParamName = envelope.createName("Request");
            reqParam = operation.addChildElement(reqParamName);
           
            for(String auxName : paramsName)
            {
                paramName = envelope.createName(auxName);
                param = reqParam.addChildElement(paramName);
View Full Code Here

            soapMessage = msgFactory.createMessage();
            SOAPEnvelope soapEnvelope = soapMessage.getSOAPPart().getEnvelope();
            soapEnvelope.addNamespaceDeclaration("xsi", "http://www.w3.org/2001/XMLSchema-instance");
            Name resName = soapFactory.createName("echoResponse", "ns1", "http://org.jboss.test.ws/jbws1186");
            SOAPBodyElement bodyElement = soapMessage.getSOAPBody().addBodyElement(resName);
            bodyElement.addChildElement("result").setAttribute("xsi:nil", "1");
            ((SOAPMessageContext)msgContext).setMessage(soapMessage);
         }
      }
      catch (Exception ex)
      {
View Full Code Here

      SOAPEnvelope envelope = sp.getEnvelope();
      SOAPBody bdy = envelope.getBody();
      SOAPBodyElement sbe = bdy.addBodyElement(envelope.createName(rpcMethodName, NS_PREFIX, NS_URI));

      // Add a some child elements
      sbe.addChildElement(envelope.createName("String_1")).addTextNode("Some hello");

      MimeHeaders headers = msg.getMimeHeaders();
      headers.addHeader("SOAPAction", "/foo/bar");
      headers.addHeader("testme", "testme");
      headers.addHeader("testme", "testme2");
View Full Code Here

            envelope.getHeader().detachNode();

            Name aName = envelope.createName(A_TAG, A_PREFIX, A_NAMESPACE_URI);
            SOAPBodyElement aBodyElement = body.addBodyElement(aName);
            aBodyElement.addChildElement(AA_TAG, A_PREFIX);
            String data = envelope.toString();

            MessageContext ctx = new MessageContext(new AxisClient());
            DeserializationContext dser = new DeserializationContext(
                    new org.xml.sax.InputSource(new StringReader(data)),
View Full Code Here

                "http://www.w3.org/2001/XMLSchema-instance");
        SOAPBodyElement bodyElement = body.addBodyElement(bodyName);

        // Create the MetaData Tag
        Name name = soapFactory.createName("MetaData");
        SOAPElement metaData = bodyElement.addChildElement(name);

        //Create the SKey Tag
        name = soapFactory.createName("SKey");
        SOAPElement sKey = metaData.addChildElement(name);
        sKey.addTextNode("SKEY001");
View Full Code Here

        SOAPElement sKey = metaData.addChildElement(name);
        sKey.addTextNode("SKEY001");

        //Create Object Tag
        name = soapFactory.createName("Object");
        SOAPElement object = bodyElement.addChildElement(name);

        //Create Book ID Tag
        name = soapFactory.createName("BookID");
        SOAPElement bookID = object.addChildElement(name);
        bookID.addTextNode("BookID002");
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.