Package javax.xml.ws

Examples of javax.xml.ws.Binding


            }
        });
        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);
        Exchange exchange = control.createMock(Exchange.class);
        expect(binding.getHandlerChain()).andReturn(list).anyTimes();
        expect(exchange.get(HandlerChainInvoker.class)).andReturn(invoker).anyTimes();
        // This is to set direction to inbound
        expect(exchange.getOutMessage()).andReturn(null);

        SoapMessage message = new SoapMessage(new MessageImpl());
View Full Code Here

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

        IMocksControl control = createNiceControl();
        Binding binding = control.createMock(Binding.class);
        expect(binding.getHandlerChain()).andReturn(list).anyTimes();
        SoapMessage message = control.createMock(SoapMessage.class);
        Exchange exchange = control.createMock(Exchange.class);
        expect(message.getExchange()).andReturn(exchange).anyTimes();
        expect(message.keySet()).andReturn(new HashSet<String>());
        expect(exchange.get(HandlerChainInvoker.class)).andReturn(invoker);
View Full Code Here

            if(portInfo.getMtomEnabled() != null &&
                Boolean.valueOf( portInfo.getMtomEnabled())) {
                mtomEnabled = true;
            }
            if (mtomEnabled) {
                Binding bType = bp.getBinding();
                // enable mtom valid only for SOAPBindings
                if(SOAPBinding.class.isAssignableFrom(bType.getClass())) {
                    ((SOAPBinding)bType).setMTOMEnabled(true);
                } else {
                    logger.log(Level.SEVERE,
                            "serviceref.invalidmtom");
                }
View Full Code Here

            if(portInfo.getMtomEnabled() != null &&
                Boolean.valueOf( portInfo.getMtomEnabled())) {
                mtomEnabled = true;
            }
            if (mtomEnabled) {
                Binding bType = bp.getBinding();
                // enable mtom valid only for SOAPBindings
                if(SOAPBinding.class.isAssignableFrom(bType.getClass())) {
                    ((SOAPBinding)bType).setMTOMEnabled(true);
                } else {
                    logger.log(Level.SEVERE, LogUtils.INVALID_MTOM, portInfo.getName());
                }
            }
View Full Code Here

public class AbstractUDDIClientTestCase extends AbstractTestCase
{
    protected void registerService(BindingProvider bindingProvider)
    {
        Binding binding = bindingProvider.getBinding();
        List<Handler> handlerChain = binding.getHandlerChain();

        handlerChain.add(new LoggingHandler());

        // set the handler chain again for the changes to take effect
        binding.setHandlerChain(handlerChain);
    }
View Full Code Here

      throws TransportException {
    return instance.subscriptionService;
}

  private void registerService(BindingProvider bindingProvider) {
    Binding binding = bindingProvider.getBinding();
    List<Handler> handlerChain = binding.getHandlerChain();

    handlerChain.add(new LoggingHandler());

    // set the handler chain again for the changes to take effect
    binding.setHandlerChain(handlerChain);
  }
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

            requestMsgCtx.setMEPContext(new MEPContext(requestMsgCtx));
            // The adapters need to be installed on the new request Message Context
            AttachmentsAdapter.install(requestMsgCtx);
            TransportHeadersAdapter.install(requestMsgCtx);
           
            Binding binding = (Binding)axisRequestMsgCtx.getProperty(PARAM_BINDING);
            InvocationContext ic = InvocationContextFactory.createInvocationContext(binding);
            ic.setRequestMessageContext(requestMsgCtx);

            //TODO:Once we the JAX-WS MessageContext one of the next things that
            //needs to be done here is setting up all of the javax.xml.ws.*
 
View Full Code Here

        SampleEndpoint sample = new SampleEndpoint();

        Endpoint ep = Endpoint.create(sample);
        assertTrue("The returned Endpoint instance was null", ep != null);

        Binding bnd = ep.getBinding();
        assertTrue("The returned Binding instance was null", bnd != null);
        assertTrue("The returned Binding instance was of the wrong type (" + bnd.getClass().getName() + "), expected SOAPBinding",
                SOAPBinding.class.isAssignableFrom(bnd.getClass()));
    }
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.