@Test public void testJaxWsPortAccessWithFeature() throws Exception { doTestJaxWsPortAccess(new AddressingFeature()); }
features.add(new AddressingFeature(addressing.enabled(), addressing.required(), addressing.responses()));
/** * Create Addressing feature. * * @return the Addressing feature */ public AddressingFeature getAddressing() { return new AddressingFeature(_addressingEnabled, _addressingRequired); }
@WebEndpoint(name = "WSHttpBinding_ICustomerService") public ICustomerService getWSHttpBindingICustomerService() { WebServiceFeature wsAddressing = new AddressingFeature(true); ICustomerService service = super.getPort(new QName("http://xmlns.example.com/services/Customer", "WSHttpBinding_ICustomerService"), ICustomerService.class, wsAddressing); Map<String, Object> context = ((BindingProvider)service).getRequestContext(); context.put(BindingProvider.USERNAME_PROPERTY, "yourusername"); context.put(BindingProvider.PASSWORD_PROPERTY, "yourpassword"); return service; }
private boolean addressibleElement(XMLStreamReader reader, WSDLFeaturedObject binding) { QName ua = reader.getName(); if (ua.equals(AddressingVersion.W3C.wsdlExtensionTag)) { String required = reader.getAttributeValue(WSDLConstants.NS_WSDL, "required"); binding.addFeature(new AddressingFeature(true, Boolean.parseBoolean(required))); XMLStreamReaderUtil.skipElement(reader); return true; // UsingAddressing is consumed } return false; }
private boolean addressibleElement(XMLStreamReader reader, WSDLFeaturedObject binding) { QName ua = reader.getName(); if (ua.equals(AddressingVersion.W3C.wsdlExtensionTag)) { String required = reader.getAttributeValue(WSDLConstants.NS_WSDL, "required"); binding.addFeature(new AddressingFeature(true, Boolean.parseBoolean(required))); XMLStreamReaderUtil.skipElement(reader); return true; // UsingAddressing is consumed } return false; }
public static CoordinatorPortType getCoordinatorPort(String action, MAP map) { CoordinatorService service = getCoordinatorService(); CoordinatorPortType port = service.getPort(CoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; configurePort(bindingProvider, action, map); return port; }
public static BusinessAgreementWithParticipantCompletionCoordinatorPortType getParticipantCompletionCoordinatorPort(W3CEndpointReference endpointReference, String action, MAP map) { BusinessAgreementWithParticipantCompletionCoordinatorService service = getParticipantCompletionCoordinatorService(); BusinessAgreementWithParticipantCompletionCoordinatorPortType port = service.getPort(endpointReference, BusinessAgreementWithParticipantCompletionCoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; configureEndpointPort(bindingProvider, action, map); return port; }
public static BusinessAgreementWithParticipantCompletionParticipantPortType getParticipantCompletionParticipantPort(W3CEndpointReference endpointReference, String action, MAP map) { BusinessAgreementWithParticipantCompletionParticipantService service = getParticipantCompletionParticipantService(); BusinessAgreementWithParticipantCompletionParticipantPortType port = service.getPort(endpointReference, BusinessAgreementWithParticipantCompletionParticipantPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; configureEndpointPort(bindingProvider, action, map); return port; }
public static BusinessAgreementWithCoordinatorCompletionCoordinatorPortType getCoordinatorCompletionCoordinatorPort(W3CEndpointReference endpointReference, String action, MAP map) { BusinessAgreementWithCoordinatorCompletionCoordinatorService service = getCoordinatorCompletionCoordinatorService(); BusinessAgreementWithCoordinatorCompletionCoordinatorPortType port = service.getPort(endpointReference, BusinessAgreementWithCoordinatorCompletionCoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; configureEndpointPort(bindingProvider, action, map); return port; }
public static CoordinatorPortType getCoordinatorPort(W3CEndpointReference endpointReference, String action, MAP map) { CoordinatorService service = getCoordinatorService(); CoordinatorPortType port = service.getPort(endpointReference, CoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; configureEndpointPort(bindingProvider, action, map); return port; }
public static CompletionCoordinatorPortType getCompletionCoordinatorPort(String action, MAP map) { CompletionCoordinatorService service = getCompletionCoordinatorService(); CompletionCoordinatorPortType port = service.getPort(CompletionCoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; configurePort(bindingProvider, action, map); return port; }
private ImagingDocumentSourcePortType port() throws Exception { ImagingDocumentSourcePortType port = service.getImagingDocumentSourcePortSoap12( new AddressingFeature(true, true), new MTOMFeature()); XDSUtils.ensureMustUnderstandHandler(port); XDSUtils.setEndpointAddress(port, url); return port; }
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) {
public static TerminationCoordinatorPortType getRegistrationPort(MAP map) { TerminationCoordinatorService service = getTerminationCoordinatorService(); TerminationCoordinatorPortType port = service.getPort(TerminationCoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; Map<String, Object> requestContext = bindingProvider.getRequestContext(); AddressingHelper.configureRequestContext(requestContext, map); AddressingHelper.configureRequestContext(requestContext, map); return port; } }
public static TerminationCoordinatorPortType getRegistrationPort(MAP map) { TerminationCoordinatorService service = getTerminationCoordinatorService(); TerminationCoordinatorPortType port = service.getPort(TerminationCoordinatorPortType.class, new AddressingFeature(true, true)); BindingProvider bindingProvider = (BindingProvider)port; Map<String, Object> requestContext = bindingProvider.getRequestContext(); AddressingHelper.configureRequestContext(requestContext, map); AddressingHelper.configureRequestContext(requestContext, map); return port; } }
private AddNumbersPortType getTwoWayPort() throws Exception { URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl"); assertNotNull("WSDL is null", wsdl); QName serviceName = new QName("http://apache.org/cxf/systest/ws/addr_feature/", "AddNumbersService"); AddNumbersService service = new AddNumbersService(wsdl, serviceName); assertNotNull("Service is null ", service); return service.getAddNumbersPort(new AddressingFeature()); }
private AddNumbersPortType getNonAnonPort() { URL wsdl = getClass().getResource("/wsdl_systest_soap12/add_numbers_soap12.wsdl"); assertNotNull("WSDL is null", wsdl); AddNumbersService service = new AddNumbersService(wsdl, serviceName); assertNotNull("Service is null ", service); return service.getAddNumbersNonAnonPort(new AddressingFeature()); }
private AddNumbersPortTypeProxy getPort()throws Exception { URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl"); assertNotNull("WSDL is null", wsdl); AddNumbersService service = new AddNumbersService(wsdl, serviceName); assertNotNull("Service is null ", service); AddNumbersPortTypeProxy port = service.getAddNumbersPort(new AddressingFeature()); updateAddressPort(port, PORT); return port; } }
private AddNumbersPortType getPort() throws Exception { URL wsdl = getClass().getResource("/wsdl_systest_wsspec/add_numbers.wsdl"); assertNotNull("WSDL is null", wsdl); AddNumbersService service = new AddNumbersService(wsdl, serviceName); assertNotNull("Service is null ", service); AddNumbersPortType port = service.getAddNumbersPort(new AddressingFeature()); updateAddressPort(port, PORT); return port; } }