Package org.apache.wsif

Examples of org.apache.wsif.WSIFPort.createOperation()


                    null,
                    null,
                    "http://wsifservice.addressbook/",
                    "AddressBook");
            WSIFPort port = service.getPort("NativeJmsPort");
            WSIFOperation op = port.createOperation("addEntry", "AddEntryWholeNameRequest", null);          
            doItPort(port, "WSIFPort_JMS");
        } catch (Exception e) {
            System.out.println(
                "\nAn error occured when running testWSIFPort_JMS " + e);
            assertTrue(false);
View Full Code Here


                    "http://www.shoppingcart.com/definitions/ShoppingCartInterface",
                    "ShoppingCart_JavaService",
                    "http://www.shoppingcart.com/definitions/ShoppingCartInterface",
                    "ShoppingCart_JavaPortType");
            WSIFPort port = service.getPort();
            WSIFOperation op = port.createOperation("addItemOperation");
            WSIFMessage message = op.createInputMessage();
            message.setObjectPart("testPart1", "test1");           
//            message.setObjectPart("testPart2", new StringTokenizer("test2"));           
            doItMessage(message);         
        } catch (Exception e) {
View Full Code Here

            WSIFServiceFactory factory = WSIFServiceFactory.newInstance();
            WSIFService dpf = factory.getService(def, service, portType);
            WSIFPort port = (portName == null) ? dpf.getPort() : dpf.getPort(portName);

            // 1st a call that should work
            WSIFOperation op1 = port.createOperation("getQuote", inputName, outputName);
            WSIFMessage input1 = op1.createInputMessage();
            WSIFMessage output1 = op1.createOutputMessage();
            WSIFMessage fault1 = op1.createFaultMessage();
            input1.setObjectPart("symbol", "");
            boolean ok = op1.executeRequestResponseOperation(input1, output1, fault1);
View Full Code Here

            assertEquals("ok getQuote response", true, ok);
            float q1 = ((Float) output1.getObjectPart("quote")).floatValue();
            assertEquals("getQuote value", -1.0F, q1, 0F);

            // now a call that is defined in WSDL but not on server
            op1 = port.createOperation("XXXgetQuote", inputName, outputName);
            input1 = op1.createInputMessage();
            output1 = op1.createOutputMessage();
            fault1 = op1.createFaultMessage();
            input1.setObjectPart("symbol", "");
            ok = op1.executeRequestResponseOperation(input1, output1, fault1);
View Full Code Here

               port = service.getPort(portName);
               Monitor.stop( testName );
            }

            WSIFOperation operation =
                port.createOperation("addEntry", "AddEntryWholeNameRequest", null);

            WSIFMessage inputMessage = operation.createInputMessage();
            WSIFMessage outputMessage = operation.createOutputMessage();
            WSIFMessage faultMessage = operation.createFaultMessage();
View Full Code Here

            testName = testNamePrefix + ".createOperation";
            iterations = (TEST_CREATEOP)? getIterations( testName ) : 1;
            System.out.println( "running " + iterations + " " + testName + " iterations..." );
            for (int i = 0; i < iterations; i++ ) {
               Monitor.start( testName );
         operation = port.createOperation("getAddressFromName");
               Monitor.stop( testName );
            }

            /*
             * Run iterations of executeRequestResponseOperation
View Full Code Here

             */
            testName = testNamePrefix + ".executeOperation";
            iterations = (TEST_EXECOP)? getIterations( testName ) : 1;
            System.out.println( "running " + iterations + " " + testName + " iterations..." );
            for (int i = 0; i < iterations; i++ ) {
         operation = port.createOperation("getAddressFromName");
         inputMessage = operation.createInputMessage();
         outputMessage = operation.createOutputMessage();
         faultMessage = operation.createFaultMessage();

         inputMessage.setObjectPart("name", nameToAdd);
View Full Code Here

        // get the port
        WSIFPort port = service.getPort();

        // create the operation
        WSIFOperation operation = port.createOperation("GetLatLong");

        // create the input, output and fault messages associated with this operation
        WSIFMessage input = operation.createInputMessage();
        WSIFMessage output = operation.createOutputMessage();
        WSIFMessage fault = operation.createFaultMessage();
View Full Code Here

        WSIFService service = factory.getService(wsdlUrl, null, null,endpoint, null);

        WSIFPort port = service.getPort();

        WSIFOperation operation = port.createOperation(getOperationName());

        WSIFMessage input = operation.createInputMessage();
        WSIFMessage output = operation.createOutputMessage();
        WSIFMessage fault = operation.createFaultMessage();
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.