Package javax.xml.ws

Examples of javax.xml.ws.Binding


    public void testAddingUnusedHandlersThroughConfigFile() {
        HandlerTestServiceWithAnnotation service1 = new HandlerTestServiceWithAnnotation(wsdl, serviceName);
        HandlerTest handlerTest1 = service1.getPort(portName, HandlerTest.class);
       
        BindingProvider bp1 = (BindingProvider)handlerTest1;
        Binding binding1 = bp1.getBinding();
        List<Handler> port1HandlerChain = binding1.getHandlerChain();
        assertEquals(1, port1HandlerChain.size());
    }
View Full Code Here


        ClientBinding cb = factory.createClientBinding(address);
        assertNotNull(cb);
        assertTrue(CorbaClientBinding.class.isInstance(cb));
       
        CorbaClientBinding clientBinding = (CorbaClientBinding)cb;
        Binding binding = clientBinding.getBinding();
        assertNotNull(binding);
        assertTrue(CorbaBindingImpl.class.isInstance(binding));
    }
View Full Code Here

        ServerBinding sb = factory.createServerBinding(address, null);
        assertNotNull(sb);
        assertTrue(CorbaServerBinding.class.isInstance(sb));
       
        CorbaServerBinding serverBinding = (CorbaServerBinding)sb;
        Binding binding = serverBinding.getBinding();
        assertNotNull(binding);
        assertTrue(CorbaBindingImpl.class.isInstance(binding));
    }
View Full Code Here

            myService.addPort(portName, null, axisEndpoint);
            Dispatch<Source> myDispatch = myService.createDispatch(portName, Source.class,
                                                                   Service.Mode.MESSAGE);

            // set handler chain for binding provider
            Binding binding = ((BindingProvider) myDispatch).getBinding();

            // create a new list or use the existing one
            List<Handler> handlers = binding.getHandlerChain();
       
            if (handlers == null)
                handlers = new ArrayList<Handler>();
            handlers.add(new AddNumbersClientLogicalHandler());
            handlers.add(new AddNumbersClientProtocolHandler());
            binding.setHandlerChain(handlers);
           
            //Invoke the Dispatch
            TestLogger.logger.debug(">> Invoking Async Dispatch");
            Source response = myDispatch.invoke(createRequestSource());
            String resString = getString(response);
View Full Code Here

            // The adapters need to be installed on the new request Message Context
            AttachmentsAdapter.install(requestMsgCtx);
            TransportHeadersAdapter.install(requestMsgCtx);
            SOAPHeadersAdapter.install(requestMsgCtx);
           
            Binding binding = (Binding)axisRequestMsgCtx.getProperty(PARAM_BINDING);
            EndpointInvocationContext eic = InvocationContextFactory.createEndpointInvocationContext(binding);
            addInvocationListenerFactories(eic);
            eic.setRequestMessageContext(requestMsgCtx);

            // WARNING: This should be left disabled for now.  This locks the server side
View Full Code Here

        JMSMTOMService service = new JMSMTOMService(wsdl, serviceName);
        assertNotNull(service);

        JMSMTOMPortType mtom = service.getPort(portName, JMSMTOMPortType.class);
        Binding binding = ((BindingProvider)mtom).getBinding();
        ((SOAPBinding)binding).setMTOMEnabled(true);

        Holder<String> name = new Holder<String>("Sam");
        URL fileURL = this.getClass().getResource("/org/apache/cxf/systest/jms/JMSClientServerTest.class");
        Holder<DataHandler> handler1 = new Holder<DataHandler>();
View Full Code Here

    public void testAddingUnusedHandlersThroughConfigFile() {
        HandlerTestServiceWithAnnotation service1 = new HandlerTestServiceWithAnnotation(wsdl, serviceName);
        HandlerTest handlerTest1 = service1.getPort(portName, HandlerTest.class);
       
        BindingProvider bp1 = (BindingProvider)handlerTest1;
        Binding binding1 = bp1.getBinding();
        List<Handler> port1HandlerChain = binding1.getHandlerChain();
        assertEquals(1, port1HandlerChain.size());
    }
View Full Code Here

            }
        });
        HandlerChainInvoker invoker1 = new HandlerChainInvoker(list);

        IMocksControl control1 = createNiceControl();
        Binding binding1 = control1.createMock(Binding.class);
        List<Handler> hList = CastUtils.cast(list);
        expect(binding1.getHandlerChain()).andReturn(hList).anyTimes();
        Exchange exchange1 = control1.createMock(Exchange.class);
        expect(exchange1.get(HandlerChainInvoker.class)).andReturn(invoker1).anyTimes();
        Message outMessage = new MessageImpl();
        outMessage.setExchange(exchange1);
        InterceptorChain chain = control1.createMock(InterceptorChain.class);
View Full Code Here

            }
        });
        HandlerChainInvoker invoker = new HandlerChainInvoker(list);

        IMocksControl control = createNiceControl();
        Binding binding = control.createMock(Binding.class);
        expect(binding.getHandlerChain()).andReturn(list).anyTimes();
        Exchange exchange = control.createMock(Exchange.class);
        expect(exchange.get(HandlerChainInvoker.class)).andReturn(invoker).anyTimes();
        SoapMessage message = new SoapMessage(new MessageImpl());
        message.setExchange(exchange);
        // This is to set direction to outbound
View Full Code Here

            }
        });
        HandlerChainInvoker invoker = new HandlerChainInvoker(list);

        IMocksControl control = createNiceControl();
        Binding binding = control.createMock(Binding.class);
        expect(binding.getHandlerChain()).andReturn(list).anyTimes();
        Exchange exchange = control.createMock(Exchange.class);
        expect(exchange.get(HandlerChainInvoker.class)).andReturn(invoker).anyTimes();
        // This is to set direction to inbound
        expect(exchange.getOutMessage()).andReturn(null);
       
View Full Code Here

TOP

Related Classes of javax.xml.ws.Binding

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.