Package org.codehaus.xfire.service

Examples of org.codehaus.xfire.service.OperationInfo


        ObjectServiceFactory factory = new ObjectServiceFactory(getXFire().getTransportManager(),
                new MessageBindingProvider())
        {
            protected OperationInfo addOperation(Service endpoint, Method method, String style)
            {
                OperationInfo op = super.addOperation(endpoint, method, style);

                new AddressingOperationInfo("http://example.com/Echo", op);

                return op;
            }
View Full Code Here


        root.addContent("hello");

        Client client = new Client(transport, service, "xfire.local://Echo", "xfire.local://Client");
        client.setXFire(getXFire());
       
        OperationInfo op = service.getServiceInfo().getOperation("echo");
        Object[] response = client.invoke(op, new Object[] {root});

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

        root.addContent("hello");

        Client client = new Client(transport, service, "xfire.local://Echo");
        client.setXFire(getXFire());
       
        OperationInfo op = service.getServiceInfo().getOperation("echo");
        try
        {
            Object[] response = client.invoke(op, new Object[] {root});

            fail("Fault was not thrown!");
View Full Code Here

        ObjectServiceFactory factory = new ObjectServiceFactory(getXFire().getTransportManager(),
                                                                new MessageBindingProvider())
        {
            protected OperationInfo addOperation(Service endpoint, Method method, String style)
            {
                OperationInfo op = super.addOperation(endpoint, method, style);
               
                new AddressingOperationInfo("http://example.com/Echo", op);
               
                return op;
            }
View Full Code Here

        Service service = getServiceFactory().create(Messenger.class);
        getServiceRegistry().register(service);
       
        assertNotNull(service.getBindingProvider());
       
        OperationInfo info = service.getServiceInfo().getOperation("receive");
        assertEquals(1, info.getInputMessage().getMessageParts().size());
       
        invokeService("Messenger", "/org/codehaus/xfire/echo11.xml");
    }
View Full Code Here

                new MessageBindingProvider())
        {

            protected OperationInfo addOperation(Service endpoint, Method method, String use)
            {
                OperationInfo op = super.addOperation(endpoint, method, use);

                new AddressingOperationInfo("http://example.org/action/notify", op);

                return op;
            }
View Full Code Here

    public void testFaultInfo()
        throws Exception
    {
        Service service = objectServiceFactory.create(EchoWithFault.class);
       
        OperationInfo op = service.getServiceInfo().getOperation("echo");
       
        assertEquals(1, op.getFaults().size());
       
        FaultInfo info = op.getFault("EchoFault");
        assertNotNull(info);
       
        assertEquals(1, info.getMessageParts().size());
        MessagePartInfo mp = info.getMessagePart(new QName(service.getName().getNamespaceURI(),
                                                           "EchoFault"));
View Full Code Here

        osf.setStyle(SoapConstants.STYLE_MESSAGE);
       
        Service service = osf.create(HeaderService.class, "HeaderService", "urn:HeaderService", null);
        getXFire().getServiceRegistry().register(service);
       
        OperationInfo op = (OperationInfo) service.getServiceInfo().getOperations().iterator().next();
        assertEquals(2, op.getInputMessage().getMessageParts().size());
       
        Binding binding = (Binding) service.getBindings().iterator().next();
        assertEquals(1, binding.getHeaders(op.getInputMessage()).getMessageParts().size());
       
        Document response = invokeService("HeaderService", "header.xml");
        assertNotNull(HeaderService.a);
        assertEquals("a", HeaderService.a.getName());
        assertNotNull(HeaderService.b);
View Full Code Here

        Service endpoint = annotationServiceFactory.create(EchoServiceImpl.class);
        ServiceInfo service = endpoint.getServiceInfo();
        assertEquals(new QName("http://xfire.codehaus.org/EchoService", "Echo"), endpoint.getName());

        final OperationInfo operation = service.getOperation("echo");
        assertNotNull(operation);

        Collection parts = operation.getInputMessage().getMessageParts();
        assertEquals(1, parts.size());
        assertEquals("input", ((MessagePartInfo) parts.iterator().next()).getName().getLocalPart());

        webAnnotationsControl.verify();
    }
View Full Code Here

        webAnnotationsControl.replay();

        Service service = annotationServiceFactory.create(EchoServiceImpl.class);
        AbstractSoapBinding binding = (AbstractSoapBinding) service.getBindings().iterator().next();
       
        OperationInfo op = service.getServiceInfo().getOperation("echo");
        assertNotNull(op);
        assertEquals(SoapConstants.USE_LITERAL, binding.getUse());
       
        webAnnotationsControl.verify();
    }
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.