Package org.codehaus.xfire.service

Examples of org.codehaus.xfire.service.OperationInfo


       
        BeanType type = new BeanType();
        tm.register(SimpleBean.class, new QName("urn:Bean", "SimpleBean"), type);
       
        ServiceInfo info = service.getServiceInfo();
        OperationInfo o = info.getOperation("getSubmitBean");
        MessageInfo inMsg = o.getInputMessage();
        MessagePartInfo p = inMsg.getMessagePart(new QName("urn:Bean", "bean"));
        p.setSchemaType(type);
       
        o = info.getOperation("getSimpleBean");
        MessageInfo outMsg = o.getOutputMessage();
        p = outMsg.getMessagePart(new QName("urn:Bean", "getSimpleBeanout"));
        p.setSchemaType(type);
    }
View Full Code Here


       
        Client client = new Client(binding, "xfire.local://" + service.getSimpleName());
        client.setXFire(getXFire());
        client.setTransport(getTransportManager().getTransport(LocalTransport.BINDING_ID));
       
        OperationInfo op = service.getServiceInfo().getOperation("echo");

        Object[] response = client.invoke(op, new Object[] {"hello"});

        assertNotNull(response);
        assertEquals(1, response.length);
View Full Code Here

        server.setPort(8191);
        server.start();
       
        Client client = new Client(new URL("http://localhost:8191/Echo?wsdl"));
       
        OperationInfo op = client.getService().getServiceInfo().getOperation("echo");

        Object[] response = client.invoke(op, new Object[] {"hello"});

        assertNotNull(response);
        assertEquals(1, response.length);
View Full Code Here

        type.setTypeClass(SimpleBean.class);
        type.setSchemaType(new QName("urn:ReallyNotSoSimpleBean", "SimpleBean"));
        type.setTypeMapping(tm);
       
        ServiceInfo info = service.getServiceInfo();
        OperationInfo o = info.getOperation("getSubmitBean");
        MessageInfo inMsg = o.getInputMessage();
        MessagePartInfo p = inMsg.getMessagePart(new QName(service.getTargetNamespace(), "bean"));
        p.setSchemaType(type);
    }
View Full Code Here

    public void testVoidAsync()
            throws Exception
    {
        Service endpoint = getServiceRegistry().getService("VoidService");
        OperationInfo op = endpoint.getServiceInfo().getOperation("doNothing");
        op.setAsync(true);
        op.setMEP(SoapConstants.MEP_IN);
        op.setOutputMessage(null);
       
        Document response =
                invokeService("VoidService",
                              "/org/codehaus/xfire/message/wrapped/voidRequest.xml");
View Full Code Here

    public void testAsyncWSDL()
            throws Exception
    {
        Service endpoint = getServiceRegistry().getService("VoidService");
        OperationInfo op = endpoint.getServiceInfo().getOperation("doNothing");
        op.setAsync(true);
        op.setMEP(SoapConstants.MEP_IN);

        Document doc = getWSDLDocument("VoidService");

        addNamespace("wsdl", WSDLWriter.WSDL11_NS);
        addNamespace("wsdlsoap", WSDLWriter.WSDL11_SOAP_NS);
View Full Code Here

        ctx.setProperty(Channel.BACKCHANNEL_URI, out);
        ctx.setExchange(new org.codehaus.xfire.exchange.MessageExchange(ctx));
        InMessage msg = new InMessage();
        ctx.getExchange().setInMessage(msg);
        if (exchange.getOperation() != null) {
            OperationInfo op = service.getServiceInfo().getOperation(exchange.getOperation().getLocalPart());
            if (op != null) {
                ctx.getExchange().setOperation(op);
            }
        }
        ctx.setCurrentMessage(msg);
View Full Code Here

        ctx.setProperty(Channel.BACKCHANNEL_URI, out);
        ctx.setExchange(new org.codehaus.xfire.exchange.MessageExchange(ctx));
        InMessage msg = new InMessage();
        ctx.getExchange().setInMessage(msg);
        if (exchange.getOperation() != null) {
            OperationInfo op = service.getServiceInfo().getOperation(exchange.getOperation().getLocalPart());
            if (op != null) {
                ctx.getExchange().setOperation(op);
            }
        }
        ctx.setCurrentMessage(msg);
View Full Code Here

        ctx.setProperty(Channel.BACKCHANNEL_URI, out);
        ctx.setExchange(new org.codehaus.xfire.exchange.MessageExchange(ctx));
        InMessage msg = new InMessage();
        ctx.getExchange().setInMessage(msg);
        if (exchange.getOperation() != null) {
            OperationInfo op = service.getServiceInfo().getOperation(exchange.getOperation().getLocalPart());
            if (op != null) {
                ctx.getExchange().setOperation(op);
            }
        }
        ctx.setCurrentMessage(msg);
View Full Code Here

        {
            throw new XFireRuntimeException("Could not find echo method on Echo class", e);
        }
        ServiceInfo serviceInfo = new ServiceInfo(new QName("http://test.xfire.codehaus.org", "EchoPortType"),
                                                  echoClass);
        OperationInfo operation = serviceInfo.addOperation("echo", echoMethod);
        MessageInfo inputMessage = operation.createMessage(new QName("echoRequest"));
        operation.setInputMessage(inputMessage);
        MessageInfo outputMessage = operation.createMessage(new QName("echoResponse"));
        operation.setOutputMessage(outputMessage);
        inputMessage.addMessagePart(new QName("echoRequestin0"), String.class);
        outputMessage.addMessagePart(new QName("echoResponseout"), String.class);

        Service service = new Service(serviceInfo);
        service.setName(new QName("http://test.xfire.codehaus.org", "Echo"));
View Full Code Here

TOP

Related Classes of org.codehaus.xfire.service.OperationInfo

Copyright © 2018 www.massapicom. 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.