@Override public Dispatch<Object> createDispatch(QName portName, JAXBContext context, Mode mode, WebServiceFeature... features) { return createDispatch(portName, Object.class, context, mode, features); }
public <T> Dispatch<T> createDispatch(QName portName, Class<T> type, JAXBContext context, Mode mode, WebServiceFeature... features) { //using this instead of JaxWsClientFactoryBean so that handlers are configured JaxWsProxyFactoryBean clientFac = new JaxWsProxyFactoryBean(); //Initialize Features. configureObject(portName.toString() + ".jaxws-client.proxyFactory", clientFac); AbstractServiceFactoryBean sf = null; try { DataBinding db; if (context != null) { db = new JAXBDataBinding(context); } else { db = new SourceDataBinding(type); } sf = createDispatchService(db); } catch (ServiceConstructionException e) { throw new WebServiceException(e); } JaxWsEndpointImpl endpoint = getJaxwsEndpoint(portName, sf, features); // if the client factory has properties specified, then set those into the endpoint if (clientFac.getProperties() != null) { endpoint.putAll(clientFac.getProperties()); } // add all the client factory features onto the endpoint feature list endpoint.getFeatures().addAll(clientFac.getFeatures());
@Override public Dispatch<Object> createDispatch(QName portName, JAXBContext context, Mode mode) { return createDispatch(portName, context, mode, new WebServiceFeature[]{}); }
public <T> Dispatch<T> createDispatch(QName portName, Class<T> type, JAXBContext context, Mode mode, WebServiceFeature... features) { //using this instead of JaxWsClientFactoryBean so that handlers are configured JaxWsProxyFactoryBean clientFac = new JaxWsProxyFactoryBean(); //Initialize Features. configureObject(portName.toString() + ".jaxws-client.proxyFactory", clientFac); AbstractServiceFactoryBean sf = null; try { DataBinding db; if (context != null) { db = new JAXBDataBinding(context); } else { db = new SourceDataBinding(type); } sf = createDispatchService(db); } catch (ServiceConstructionException e) { throw new WebServiceException(e); } JaxWsEndpointImpl endpoint = getJaxwsEndpoint(portName, sf, features); // if the client factory has properties specified, then set those into the endpoint if (clientFac.getProperties() != null) { endpoint.putAll(clientFac.getProperties()); } // add all the client factory features onto the endpoint feature list endpoint.getFeatures().addAll(clientFac.getFeatures());
@Override public <T> Dispatch<T> createDispatch(QName portName, Class<T> type, Mode mode) { return createDispatch(portName, type, mode, new WebServiceFeature[]{}); }
@Override public <T> Dispatch<T> createDispatch(EndpointReference endpointReference, Class<T> type, Mode mode, WebServiceFeature... features) { EndpointReferenceType ref = ProviderImpl.convertToInternal(endpointReference); QName portName = EndpointReferenceUtils.getPortQName(ref, bus); updatePortInfoAddress(portName, EndpointReferenceUtils.getAddress(ref)); return createDispatch(portName, type, mode, features); }
@Override public Dispatch<Object> createDispatch(EndpointReference endpointReference, JAXBContext context, Mode mode, WebServiceFeature... features) { EndpointReferenceType ref = ProviderImpl.convertToInternal(endpointReference); QName portName = EndpointReferenceUtils.getPortQName(ref, bus); updatePortInfoAddress(portName, EndpointReferenceUtils.getAddress(ref)); return createDispatch(portName, context, mode, features); }
@Override public Dispatch<Object> createDispatch(QName portName, JAXBContext context, Mode mode, WebServiceFeature... features) { return createDispatch(portName, Object.class, context, mode, features); }
@Override public Dispatch<Object> createDispatch(QName portName, JAXBContext context, Mode mode) { return createDispatch(portName, context, mode, new WebServiceFeature[]{}); }
@Override public <T> Dispatch<T> createDispatch(QName portName, Class<T> type, Mode mode) { return createDispatch(portName, type, mode, new WebServiceFeature[]{}); }
@Override public <T> Dispatch<T> createDispatch(QName portName, Class<T> type, JAXBContext context, Mode mode, WebServiceFeature... features) { Dispatch<T> dispatch = super.createDispatch(portName, type, context, mode, features); setupClient(dispatch, null, features); return dispatch; }
@Override public Dispatch<Object> createDispatch(EndpointReference endpointReference, JAXBContext context, Mode mode, WebServiceFeature... features) { EndpointReferenceType ref = ProviderImpl.convertToInternal(endpointReference); QName portName = EndpointReferenceUtils.getPortQName(ref, bus); updatePortInfoAddress(portName, EndpointReferenceUtils.getAddress(ref)); return createDispatch(portName, context, mode, features); }
@Override public <T> Dispatch<T> createDispatch(EndpointReference endpointReference, Class<T> type, Mode mode, WebServiceFeature... features) { EndpointReferenceType ref = ProviderImpl.convertToInternal(endpointReference); QName portName = EndpointReferenceUtils.getPortQName(ref, bus); updatePortInfoAddress(portName, EndpointReferenceUtils.getAddress(ref)); return createDispatch(portName, type, mode, features); }
private synchronized Dispatch<Object> getDispatchInternal(boolean addSeq, String action) { if (dispatch == null) { AddressingFeature f = new AddressingFeature(true, true); dispatch = getService().createDispatch(version.getServiceName(), getJAXBContext(), Service.Mode.PAYLOAD, f); dispatch.getRequestContext().put("thread.local.request.context", Boolean.TRUE); version.addVersionTransformer(dispatch); } addAddressing(dispatch, false, action); return dispatch; } private void addAddressing(BindingProvider p, boolean addSeq, String action) {
private synchronized Dispatch<Object> getDispatchInternal(boolean addSeq, String action) { if (dispatch == null) { AddressingFeature f = new AddressingFeature(true, true); dispatch = getService().createDispatch(version.getServiceName(), getJAXBContext(), Service.Mode.PAYLOAD, f); dispatch.getRequestContext().put("thread.local.request.context", Boolean.TRUE); version.addVersionTransformer(dispatch); } addAddressing(dispatch, false, action); return dispatch; } private void addAddressing(BindingProvider p, boolean addSeq, String action) {