Examples of Greeter


Examples of org.objectweb.hello_world_soap_http.Greeter

        assertNotNull(service);

        String response1 = new String("TestGreetMeResponse");
        String response2 = new String("TestSayHiResponse");
        try {
            Greeter greeter = service.getPort(portName, Greeter.class);
            String greeting = greeter.greetMe("TestGreetMeRequest");
            assertNotNull("no response received from service", greeting);
            assertEquals(response1, greeting);

            String reply = greeter.sayHi();
            assertNotNull("no response received from service", reply);
            assertEquals(response2, reply);
        } catch (UndeclaredThrowableException ex) {
            ex.printStackTrace();
            throw (Exception)ex.getCause();
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

        assertNotNull(service);

        String response1 = new String("TestGreetMeResponse");
        String response2 = new String("TestSayHiResponse");
        try {
            Greeter greeter = service.getPort(portName, Greeter.class);
            String greeting = greeter.greetMe("TestGreetMeRequest");
            assertNotNull("no response received from service", greeting);
            assertEquals(response1, greeting);

            String reply = greeter.sayHi();
            assertNotNull("no response received from service", reply);
            assertEquals(response2, reply);
        } catch (UndeclaredThrowableException ex) {
            ex.printStackTrace();
            throw (Exception)ex.getCause();
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

        assertNotNull(wsdl);
       
        SOAPService service = new SOAPService(wsdl, serviceName);
        assertNotNull(service);
       
        Greeter greeter = service.getPort(portName, Greeter.class);
       
        String response1 = new String("Hello Milestone-");
        String response2 = new String("Bonjour");
        try {      
            for (int idx = 0; idx < 5; idx++) {
                String greeting = greeter.greetMe("Milestone-" + idx);
                assertNotNull("no response received from service", greeting);
                String exResponse = response1 + idx;
                assertEquals(exResponse, greeting);
               
                String reply = greeter.sayHi();
                assertNotNull("no response received from service", reply);
                assertEquals(response2, reply);

                greeter.greetMeOneWay("Milestone-" + idx);
               
                BareDocumentResponse bareres = greeter.testDocLitBare("MySimpleDocument");
                assertNotNull("no response for operation testDocLitBare", bareres);
                assertEquals("Celtix", bareres.getCompany());
                assertTrue(bareres.getId() == 1)
               
            }           
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

        service.setExecutor(executor);
        assertNotNull(service);

        String expectedString = new String("How are you Joe");
        try {
            Greeter greeter = (Greeter)service.getPort(portName, Greeter.class);
           
            Response<GreetMeSometimeResponse> response = greeter.greetMeSometimeAsync("Joe");
            while (!response.isDone()) {
                Thread.sleep(100);
            }
            GreetMeSometimeResponse reply = response.get();
            assertNotNull("no response received from service", reply);
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

                String s = reply.getResponseType();
                assertEquals(expectedString, s);  
            }
        }
       
        Greeter greeter = (Greeter)service.getPort(portName, Greeter.class);
        Response<GreetMeSometimeResponse> response = greeter.greetMeSometimeAsync("Joe");
       
        Poller[] pollers = new Poller[4];
        for (int i = 0; i < pollers.length; i++) {
            pollers[i] = new Poller(response, i);
        }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

        MyHandler h = new MyHandler();
        MyHandler.invocationCount = 0;

        String expectedString = new String("How are you Joe");
        try {
            Greeter greeter = (Greeter)service.getPort(portName, Greeter.class);
            Future<?> f = greeter.greetMeSometimeAsync("Joe", h);
            int i = 0;
            while (!f.isDone() && i < 20) {
                Thread.sleep(100);
                i++;
            }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

                assertEquals("callback was not executed or did not return the expected result",
                             expectedString, h.getReplyBuffer());
            }
        }
       
        Greeter greeter = (Greeter)service.getPort(portName, Greeter.class);
        Future<?> f = greeter.greetMeSometimeAsync("Joe", h);
       
        Poller[] pollers = new Poller[4];
        for (int i = 0; i < pollers.length; i++) {
            pollers[i] = new Poller(f, i);
        }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http.Greeter

        assertNotNull(service);

        String noSuchCodeFault = "NoSuchCodeLitFault";
        String badRecordFault = "BadRecordLitFault";

        Greeter greeter = service.getPort(portName, Greeter.class);
        for (int idx = 0; idx < 2; idx++) {
            try {
                greeter.testDocLitFault(noSuchCodeFault);
                fail("Should have thrown NoSuchCodeLitFault exception");
            } catch (NoSuchCodeLitFault nslf) {
                assertNotNull(nslf.getFaultInfo());
                assertNotNull(nslf.getFaultInfo().getCode());
            }
           
            try {
                greeter.testDocLitFault(badRecordFault);
                fail("Should have thrown BadRecordLitFault exception");
            } catch (BadRecordLitFault brlf) {
                assertNotNull(brlf.getFaultInfo());
            }
        }
View Full Code Here

Examples of org.objectweb.hello_world_soap_http_secure.Greeter

            SecureSOAPService service = new SecureSOAPService(wsdl, serviceName);
            assertNotNull(service);
           
            QName portName = new QName("http://objectweb.org/hello_world_soap_http_secure",
                                       Matrix.TWO_TIER_TESTS[index].clientData.clientPortName);
            Greeter greeter = service.getPort(portName, Greeter.class);
            String propStr = "celtix.security.configurer"
                + ".celtix.{http://objectweb.org/hello_world_soap_http_secure}"
                + Matrix.TWO_TIER_TESTS[index].clientData.clientServiceName + "/"
                + Matrix.TWO_TIER_TESTS[index].clientData.clientPortName + ".http-client";
            if (Matrix.TWO_TIER_TESTS[index].clientData.securityConfigurer != null) {
View Full Code Here

Examples of org.objectweb.hello_world_soap_http_secure.Greeter

            SecureSOAPService service = new SecureSOAPService(wsdl, serviceName);
            assertNotNull(service);
           
            QName portName = new QName("http://objectweb.org/hello_world_soap_http_secure",
                                       Matrix.THREE_TIER_TESTS[index].clientData.clientPortName);
            Greeter greeter = service.getPort(portName, Greeter.class);
           
            invokeThreeTier(greeter, index);
        }
    } 
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.