Examples of invokeBlocking()


Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        ArrayList args = new ArrayList();
        String [] values = new String[] { "abc", "cde", "efg" };
        args.add(values);
        ArrayList ret = new ArrayList();
        ret.add(Boolean.class);
        Object [] objs = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "handleStringArray", "req"), args.toArray(),
                                               (Class[])ret.toArray(new Class[ret.size()]));
        assertNotNull(objs);
        assertEquals(Boolean.TRUE, Boolean.valueOf(objs[0].toString()));
    }
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        args.add(values3);
        args.add("10");

        ArrayList ret = new ArrayList();
        ret.add(Integer.class);
        Object [] objs = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "multiArrays", "req"), args.toArray(),
                                               (Class[])ret.toArray(new Class[ret.size()]));
        assertNotNull(objs);
        assertEquals(19, Integer.parseInt(objs[0].toString()));
    }
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        ArrayList args = new ArrayList();
        args.add("foo");


        OMElement element = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "mulReturn", "req"), args.toArray());
        System.out.println("element = " + element);
//        assertEquals(response.getFirstElement().getText(), "foo");
    }

View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        Object[] opGetWeatherArgs = new Object[] { };
        Class[] returnTypes = new Class[] { Weather.class };
       
       
        Object[] response = serviceClient.invokeBlocking(opGetWeather,
                opGetWeatherArgs, returnTypes);
       
        Weather result = (Weather) response[0];
       
        // display results
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        ArrayList args = new ArrayList();
        args.add(bean);
        args.add("159");

        OMElement response = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "editBean", "req"), args.toArray());
        MyBean resBean = (MyBean)BeanUtil.deserialize(MyBean.class, response.getFirstElement(),
                                                      new DefaultObjectSupplier(), null);
        assertNotNull(resBean);
        assertEquals(resBean.getAge(), 159);
    }
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        ArrayList args = new ArrayList();
        args.add(bean);


        OMElement response = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "echoBean", "req"), args.toArray());
        MyBean resBean = (MyBean)BeanUtil.deserialize(MyBean.class,
                                                      response.getFirstElement(),
                                                      new DefaultObjectSupplier(), null);
//        MyBean resBean =(MyBean) new  BeanSerializer(MyBean.class,response).deserilze();
        assertNotNull(resBean);
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

        ArrayList args = new ArrayList();
        args.add(mail);


        OMElement response = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "echoMail", "req"), args.toArray());
        Mail resBean = (Mail)BeanUtil.deserialize(Mail.class, response.getFirstElement(),
                                                  new DefaultObjectSupplier(), null);
//        MyBean resBean =(MyBean) new  BeanSerializer(MyBean.class,response).deserilze();
        assertNotNull(resBean);
        assertEquals(resBean.getBody(), "My Body");
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

    public void testEchoString() throws AxisFault {
      RPCServiceClient sender = getRPCClient("EchoXMLService", "echoString");

        ArrayList args = new ArrayList();
        args.add("foo");
        OMElement response = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "echoString", "req"), args.toArray());
        assertEquals(response.getFirstElement().getText(), "foo");
    }

    public void testEchoInt() throws AxisFault {
      RPCServiceClient sender = getRPCClient("EchoXMLService", "echoInt");
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

      RPCServiceClient sender = getRPCClient("EchoXMLService", "echoInt");

        ArrayList args = new ArrayList();
        args.add("100");

        OMElement response = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "echoInt", "req"), args.toArray());
        assertEquals(Integer.parseInt(response.getFirstElement().getText()), 100);
    }

    public void testAdd() throws AxisFault {
      RPCServiceClient sender = getRPCClient("EchoXMLService", "add");
View Full Code Here

Examples of org.apache.axis2.rpc.client.RPCServiceClient.invokeBlocking()

     
        ArrayList args = new ArrayList();
        args.add("100");
        args.add("200");

        OMElement response = sender.invokeBlocking(new QName("http://rpc.axis2.apache.org", "add", "req"), args.toArray());
        assertEquals(Integer.parseInt(response.getFirstElement().getText()), 300);
    }

    public void testByteArray() throws AxisFault {
      RPCServiceClient sender = getRPCClient("EchoXMLService", "testByteArray");
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.