Package javax.xml.ws.soap

Examples of javax.xml.ws.soap.AddressingFeature


        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);
        return service.getAddNumbersPort(new AddressingFeature());
    }
View Full Code Here


        if (addressing == null && serviceClass != null) {
            addressing = serviceClass.getAnnotation(Addressing.class);
        }

        if (addressing != null) {
            features.add(new AddressingFeature(addressing.enabled(), addressing.required()));
        }

        if (features.size() > 0) {
            wsFeatures = features;
        }
View Full Code Here

        }
        return null;
    }
   
    public final void resolveFeatures() {
        AddressingFeature addressing = getAddressingFeature();
        if (addressing == null) {
            return;
        }
        if (addressing.isEnabled()) {
            WSAddressingFeature feature = getWSAddressingFeature();
            if (feature == null) {
                feature = new WSAddressingFeature();
                addAddressingFeature(feature);
            }
            feature.setAddressingRequired(addressing.isRequired());
            if (ProviderImpl.isJaxWs22()) {
                try {
                    Class<?> addrClass = ClassLoaderUtils.loadClass("javax.xml.ws.soap.AddressingFeature",
                                                                    ProviderImpl.class);
                    Method responsesMethod = addrClass.getMethod("getResponses", new Class[] {});
View Full Code Here

        if (addressing == null && serviceClass != null) {
            addressing = serviceClass.getAnnotation(Addressing.class);
        }

        if (addressing != null) {
            features.add(new AddressingFeature(addressing.enabled(), addressing.required()));
        }

        if (features.size() > 0) {
            wsFeatures = features;
        }
View Full Code Here

    /*
     * Test the default configuration of the AddressingFeature.
     */
    public void testDefaultAddressingFeature() throws Exception {
        // Use the default feature config
        AddressingFeature feature = new AddressingFeature();
       
        Service svc = Service.create(new QName("http://test", "ProxyAddressingService"));
        ProxyAddressingService proxy = svc.getPort(w3cEPR, ProxyAddressingService.class, feature);
        assertNotNull(proxy);
       
View Full Code Here

    /*
     * Test disabling the Addressing feature.
     */
    public void testDisabledAddressingFeature() {
        // Set the feature to be disabled.
        AddressingFeature feature = new AddressingFeature(false);
       
        Service svc = Service.create(new QName("http://test", "ProxyAddressingService"));
        ProxyAddressingService proxy = svc.getPort(w3cEPR, ProxyAddressingService.class, feature);
        assertTrue("Proxy instance was null", proxy != null);
       
View Full Code Here

    /*
     * Test requiring the AddressingFeature.
     */
    public void testRequiredAddressingFeature() throws Exception {
        // Set the feature to be required.
        AddressingFeature feature = new AddressingFeature(true, true);
       
        Service svc = Service.create(new QName("http://test", "ProxyAddressingService"));
        ProxyAddressingService proxy = svc.getPort(w3cEPR, ProxyAddressingService.class, feature);
        assertNotNull(proxy);
       
View Full Code Here

    /*
     * Test the default configuration of the AddressingFeature.
     */
    public void testInvalidAddressingFeature() {
        // Use the default feature config
        AddressingFeature feature = new AddressingFeature();
       
        Service svc = Service.create(new QName("http://test", "ProxyAddressingService"));
        ProxyAddressingService proxy = svc.getPort(subEPR, ProxyAddressingService.class, feature);
        assertNotNull(proxy);
       
View Full Code Here

    /*
     * Test the default configuration of the AddressingFeature.
     */
    public void testDefaultAddressingFeature() throws Exception {
        // Use the default feature config
        AddressingFeature feature = new AddressingFeature();
       
        Service svc = Service.create(new QName("http://test", "TestService"));
        svc.addPort(new QName("http://test", "TestPort"), SOAPBinding.SOAP11HTTP_BINDING, "http://localhost");
        Dispatch<Source> d = svc.createDispatch(w3cEPR, Source.class, Service.Mode.PAYLOAD, feature);
       
View Full Code Here

    /*
     * Test disabling the Addressing feature.
     */
    public void testDisabledAddressingFeature() {
        // Set the feature to be disabled.
        AddressingFeature feature = new AddressingFeature(false);
               
        Service svc = Service.create(new QName("http://test", "TestService"));
        svc.addPort(new QName("http://test", "TestPort"), SOAPBinding.SOAP11HTTP_BINDING, "http://localhost");       
        Dispatch<Source> d = svc.createDispatch(w3cEPR, Source.class, Service.Mode.PAYLOAD, feature);
       
View Full Code Here

TOP

Related Classes of javax.xml.ws.soap.AddressingFeature

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.