Package org.apache.axis2.soap

Examples of org.apache.axis2.soap.SOAPFactory.createOMNamespace()


        return listMyQueues;
    }

    public static OMElement read(String requiredQueueName, String key) {
        SOAPFactory factory = OMAbstractFactory.getSOAP11Factory();
        OMNamespace opN = factory.createOMNamespace(
                "http://webservices.amazon.com/AWSSimpleQueueService/2005-01-01",
                "nsQ");
        OMElement read = factory.createOMElement("Read", opN);
        OMElement subID = factory.createOMElement("SubscriptionId", opN);
        OMElement request = factory.createOMElement("Request", opN);
View Full Code Here


    }

    public void testSendingMustUnderstandWithNextRole() throws Exception {
        SOAPFactory fac = OMAbstractFactory.getSOAP12Factory();
        SOAPEnvelope envelope = fac.getDefaultEnvelope();
        OMNamespace headerNs = fac.createOMNamespace("http://dummyHeader", "dh");
        SOAPHeaderBlock h1 =
                fac.createSOAPHeaderBlock("DummyHeader", headerNs, envelope.getHeader());
        h1.setMustUnderstand(true);
        h1.addChild(fac.createText("Dummy String"));
        h1.setRole(SOAP12Constants.SOAP_ROLE_NEXT);
View Full Code Here

            Object resObject = method.invoke(obj, objectArray);
            SOAPFactory fac = getSOAPFactory(inMessage);

            // Handling the response
            //todo NameSpace has to be taken from the AxisService
            OMNamespace ns = fac.createOMNamespace(
                    "http://soapenc/", "res");
            SOAPEnvelope envelope = fac.getDefaultEnvelope();
            OMElement bodyContent = null;

            if (resObject instanceof Object[]) {
View Full Code Here

        namespace = reqEnv.declareNamespace("http://schemas.xmlsoap.org/wsdl/",
                "wsdl");
        namespace = reqEnv.declareNamespace("http://webservices.amazon.com/AWSAlexa/2005-02-01",
                "tns");

        nulNS = omFactory.createOMNamespace("", "");

        operation = omFactory.createOMElement("Search",
                "http://webservices.amazon.com/AWSAlexa/2005-02-01", "ns1");
        reqEnv.getBody().addChild(operation);
        operation.addAttribute("encordingStyle", "http://schemas.xmlsoap.org/soap/encoding/", null);
View Full Code Here

                    // invoke the WebService
                    OMElement result = (OMElement) method.invoke(obj, parms);
                    SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();
                    envelope = fac.getDefaultEnvelope();

                    OMNamespace ns = fac.createOMNamespace("http://soapenc/", "res");
                    OMElement responseMethodName = fac.createOMElement(methodName + "Response", ns);
                    if (result != null) {
                        responseMethodName.addChild(result);
                    }
                    if (responseMethodName != null) {
View Full Code Here

    private void callTheService() throws Exception {
        try {
            SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();
                           
            OMNamespace omNs = fac.createOMNamespace("http://localhost/my", "my");
            OMElement method = fac.createOMElement("echoOMElement", omNs);
            OMElement value = fac.createOMElement("myValue", omNs);
            value.setText("Isaac Assimov, the foundation Sega");
            method.addChild(value);
View Full Code Here

        TestingUtils.campareWithCreatedOMElement(result);
        call.close();
    }
    public void testDispatchWithURLAndSOAPAction() throws Exception {
        SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();
        OMNamespace omNs = fac.createOMNamespace("http://dummyURL", "my");
        OMElement payload = fac.createOMElement("echoOMElementRequest", omNs);
        OMElement value = fac.createOMElement("myValue", omNs);
        value.addChild(fac.createText(value, "Isaac Assimov, the foundation Sega"));
        payload.addChild(value);
        org.apache.axis2.clientapi.Call call = new org.apache.axis2.clientapi.Call();
View Full Code Here

    }

    public void testDispatchWithSOAPBody() throws Exception {
        SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();

        OMNamespace omNs = fac.createOMNamespace("http://127.0.0.1:5555/axis/services/EchoXMLService", "my");
        OMElement payload = fac.createOMElement("echoOMElement", omNs);
        OMElement value = fac.createOMElement("myValue", omNs);
        value.addChild(fac.createText(value, "Isaac Assimov, the foundation Sega"));
        payload.addChild(value);
View Full Code Here

    if (values[1] != null && values[0] != null) {
      String operation = values[1];
      SOAPFactory soapFactory = new SOAP11Factory();
      SOAPEnvelope envelope = soapFactory.getDefaultEnvelope();

      OMNamespace omNs = soapFactory.createOMNamespace(values[0],
          "services");
      OMNamespace defualtNs = new OMNamespaceImpl("", null);

      OMElement opElement = soapFactory.createOMElement(operation, omNs);
View Full Code Here

    public void testEchoXMLSync() throws Exception {
        try {
            SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();

            SOAPEnvelope reqEnv = fac.getDefaultEnvelope();
            OMNamespace omNs = fac.createOMNamespace("http://localhost/my", "my");
            OMElement method = fac.createOMElement("echoOMElement", omNs);
            OMElement value = fac.createOMElement("myValue", omNs);
            value.addChild(fac.createText(value, "Isaac Assimov, the foundation Sega"));
            method.addChild(value);
            reqEnv.getBody().addChild(method);
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.