Package javax.xml.ws

Examples of javax.xml.ws.WebServiceClient


        assertSame(composite, svcDescComposite.getSparseComposite(compositeKey));
        // The client annot we set as a sparse composite should be the same.
        assertSame(wsClientAnno, svcDescComposite.getSparseComposite(compositeKey).getWebServiceClientAnnot());
        // The WebServiceClient annot on the service desc should represent the wsdl override from the
        // sparse composite
        WebServiceClient wsClient = svcDescComposite.getWebServiceClientAnnot(compositeKey);
        assertEquals(overridenWsdlLocation, wsClient.wsdlLocation());
        // Make sure the non-overridden values still come from the service class annotation
        assertEquals("originalTNS", wsClient.targetNamespace());
        assertEquals("", wsClient.name());
       
    }
View Full Code Here


   
    URL getSparseCompositeWsdlURL(DescriptionBuilderComposite sparseComposite) {
        // Use the WSDL file if it is specified in the composite
        URL url = null;
        if (sparseComposite != null) {
            WebServiceClient wsc = (WebServiceClient) sparseComposite.getWebServiceClientAnnot();
            if (wsc != null && wsc.wsdlLocation() != null) {
                String wsdlLocation = wsc.wsdlLocation();
                URL wsdlUrl = getWSDLURL(wsdlLocation);
               
                if (wsdlUrl == null) {
                    throw ExceptionFactory.makeWebServiceException(Messages.getMessage("serviceDescErr4", wsdlLocation));
                } else {
View Full Code Here

        assertNotNull(serviceDesc);
        DescriptionBuilderComposite dbcInServiceDesc = DescriptionTestUtils2.getServiceDescriptionComposite(serviceDesc);
        assertNotNull(dbcInServiceDesc);
        assertEquals(Service.class, dbcInServiceDesc.getCorrespondingClass());
        // Since this is a generic Service with no overrides, there will be no WebServiceClient annotation
        WebServiceClient wsClient = dbcInServiceDesc.getWebServiceClientAnnot();
        assertNull(wsClient);

        // WSDL was specified on the create, so make sure the right one was used by checking the ports
        assertTrue("Wrong WSDL used", ClientMetadataTest.validatePort(service, otherWsdl_portLocalPart));
       
View Full Code Here

        if (service == null) {
          //if wsdl is null, try and get it from the WebServiceClient.wsdlLocation
          if(wsdl == null){
              if(serviceClass != Service.class){
                  WebServiceClient wsClient = AccessController.doPrivileged(new PrivilegedAction<WebServiceClient>() {
                          public WebServiceClient run() {
                              return serviceClass.getAnnotation(WebServiceClient.class);
                          }
                      });
                  String wsdlLocation = wsClient.wsdlLocation();
                  wsdlLocation = JAXWSUtils.absolutize(JAXWSUtils.getFileOrURLName(wsdlLocation));
                  wsdl = new StreamSource(wsdlLocation);
              }
          }
          if (wsdl != null) {
View Full Code Here

        if (wsAnn != null) {
            return true;
        }

        // Check for service
        WebServiceClient wscAnn = (WebServiceClient)getAnnotation(cls,WebServiceClient.class);
        if (wscAnn != null) {
            return true;
        }

        // Check for provider
View Full Code Here

     * <code>DescriptionBuildercomposite</code>
     *
     * @param composite - <code>DescriptionBuilderComposite</code>
     */
    private void attachWebServiceClientAnnotation(DescriptionBuilderComposite composite) {
        WebServiceClient webServiceClient = (WebServiceClient)ConverterUtils.
                getAnnotation(WebServiceClient.class, serviceClass);
        if (webServiceClient != null) {

        }

View Full Code Here

                                                        SparseAnnotServiceSubclass.class);
        assertNotNull(svcDesc);
        // A DBC will be created for us
        DescriptionBuilderComposite svcDescComposite = DescriptionTestUtils.getServiceDescriptionComposite(svcDesc);
        assertNotNull(svcDescComposite);
        WebServiceClient wsClient = svcDescComposite.getWebServiceClientAnnot();
        // There is no DBC Annot in this case; it is the class annotation but it should be
        // returned as an instance of a WebServiceClientAnnot
        assertTrue(wsClient instanceof WebServiceClientAnnot);
    }
View Full Code Here

        DescriptionBuilderComposite svcDescComposite = DescriptionTestUtils.getServiceDescriptionComposite(svcDesc);
        assertNotNull(svcDescComposite);
        assertNotSame(composite, svcDescComposite);
        assertSame(SparseAnnotServiceSubclass.class, svcDescComposite.getCorrespondingClass());
        assertSame(composite, svcDescComposite.getSparseComposite(compositeKey));
        WebServiceClient wsClient = svcDescComposite.getWebServiceClientAnnot();
        assertTrue(wsClient instanceof WebServiceClientAnnot);
    }
View Full Code Here

        assertNotNull(serviceDesc);
        DescriptionBuilderComposite dbcInServiceDesc = DescriptionTestUtils2.getServiceDescriptionComposite(serviceDesc);
        assertNotNull(dbcInServiceDesc);
        assertEquals(Service.class, dbcInServiceDesc.getCorrespondingClass());
        // Since this is a generic Service with no overrides, there will be no WebServiceClient annotation
        WebServiceClient wsClient = dbcInServiceDesc.getWebServiceClientAnnot();
        assertNull(wsClient);
       
        // No WSDL should have been used, so no Ports should be found
        assertTrue("Wrong WSDL used", validatePort(service, null));
    }   
View Full Code Here

        assertNotNull(serviceDesc);
        DescriptionBuilderComposite dbcInServiceDesc = DescriptionTestUtils2.getServiceDescriptionComposite(serviceDesc);
        assertNotNull(dbcInServiceDesc);
        assertEquals(Service.class, dbcInServiceDesc.getCorrespondingClass());
        // Since this is a generic Service with no overrides, there will be no WebServiceClient annotation
        WebServiceClient wsClient = dbcInServiceDesc.getWebServiceClientAnnot();
        assertNull(wsClient);

        // WSDL was specified on the create, so make sure the right one was used by checking the ports
        assertTrue("Wrong WSDL used", validatePort(service, otherWsdl_portLocalPart));
    }
View Full Code Here

TOP

Related Classes of javax.xml.ws.WebServiceClient

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.