Package com.sun.enterprise.deployment

Examples of com.sun.enterprise.deployment.WebServicesDescriptor


                ejbGeneratedOptionalLocalBusinessIntfClass = optIntfClassLoader.loadClass(optIntfClassName);
            }

            if( isStatelessSession || isSingleton ) {
                EjbBundleDescriptorImpl bundle = ejbDescriptor.getEjbBundleDescriptor();
                WebServicesDescriptor webServices = bundle.getWebServices();
                Collection endpoints = webServices.getEndpointsImplementedBy(ejbDescriptor);
                // JSR 109 doesn't require support for a single ejb
                // implementing multiple port ex.
                if( endpoints.size() == 1 ) {

                    assertFullProfile("is a Web Service Endpoint");
View Full Code Here


        if( isWebServiceEndpoint ) {

            EjbBundleDescriptorImpl bundle =
                ejbDescriptor.getEjbBundleDescriptor();
            WebServicesDescriptor webServices = bundle.getWebServices();
            Collection myEndpoints =
                webServices.getEndpointsImplementedBy(ejbDescriptor);


            // An ejb can only be exposed through 1 web service endpoint
            Iterator iter = myEndpoints.iterator();
            webServiceEndpoint =
View Full Code Here

        if(portName == null) {
            portName = "";
        }
       
        // Check if the same endpoint is already defined in webservices.xml
        WebServicesDescriptor wsDesc = bundleDesc.getWebServices();
        WebServiceEndpoint endpoint = wsDesc.getEndpointByName(portComponentName);
        WebService newWS;
        if(endpoint == null) {
            // Check if a service with the same name is already present
            // If so, add this endpoint to the existing service
            if (svcName.length()!=0) {
                newWS = wsDesc.getWebServiceByName(svcName);
            } else {
                newWS = wsDesc.getWebServiceByName(((Class)annElem).getSimpleName()+"Service");
            }
            if(newWS==null) {
                newWS = new WebService();
                // service name from annotation
                if (svcName.length()!=0) {
                    newWS.setName(svcName);
                } else {
                    newWS.setName(((Class)annElem).getSimpleName()+"Service");           
                }
                wsDesc.addWebService(newWS);
            }
            endpoint = new WebServiceEndpoint();
            // port-component-name is fully qualified class name
            endpoint.setEndpointName(portComponentName);
            newWS.addEndpoint(endpoint);           
            wsDesc.setSpecVersion(com.sun.enterprise.deployment.node.WebServicesDescriptorNode.SPEC_VERSION);           
        } else {
            newWS = endpoint.getWebService();
        }

        // If wsdl-service is specified in the descriptor, then the targetnamespace
View Full Code Here

            ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
            servletName = servletConfig.getServletName();
            WebComponentDescriptor webComponent =
                    webBundle.getWebComponentByCanonicalName(servletName);
            if( webComponent != null ) {
                WebServicesDescriptor webServices = webBundle.getWebServices();
                Collection endpoints =
                        webServices.getEndpointsImplementedBy(webComponent);
                // Only 1 endpoint per servlet is supported, even though
                // data structure implies otherwise.
                endpoint_ = (WebServiceEndpoint) endpoints.iterator().next();
                registerEndpoint(classLoader);
View Full Code Here

            if (getParentNode() instanceof WebBundleRuntimeNode) {
                parent = ((WebBundleRuntimeNode) getParentNode()).getWebBundleDescriptor();
            } else {
                parent = (BundleDescriptor) getParentNode().getDescriptor();
            }
            WebServicesDescriptor webServices = parent.getWebServices();
            descriptor = webServices.getWebServiceByName(value);
        } else if( WebServicesTagNames.CLIENT_WSDL_PUBLISH_URL.equals
                   (element.getQName()) ) {
            if( descriptor == null ) {
                DOLUtils.getDefaultLogger().info
                    ("Warning : WebService descriptor is null for "
View Full Code Here

     * @param parent node to add the runtime xml info
     * @param the bundle descriptor
     */       
    public void writeWebServiceRuntimeInfo(Node parent,
                                           BundleDescriptor bundle) {
        WebServicesDescriptor webServices = bundle.getWebServices();
        if( webServices != null ) {
            for(Iterator iter = webServices.getWebServices().iterator();
                iter.hasNext();) {
                WebService next = (WebService) iter.next();
                if( next.hasClientPublishUrl() ) {
                    writeDescriptor
                        (parent, WebServicesTagNames.WEB_SERVICE, next);
View Full Code Here

            return BundleDescriptor.class.cast(descriptor).getWebServices();
        }
    }

    public RootDeploymentDescriptor getDefaultDescriptor() {
        return new WebServicesDescriptor();
    }
View Full Code Here

                subEntries.add(JarFile.MANIFEST_NAME);
  
                BundleDescriptor subBundleDesc =
                    (BundleDescriptor) md.getDescriptor();
                // all mapping file stay within the embedded jar
                WebServicesDescriptor wsd = subBundleDesc.getWebServices();
                if (wsd!=null) {
                    for (Iterator itr = wsd.getWebServices().iterator();itr.hasNext();) {
                        WebService ws = (WebService) itr.next();
                        subEntries.add(ws.getMappingFileUri());
                    }               
                }
               
View Full Code Here

     * @param node name
     * @param the descriptor to write
     * @return the DOM tree top node
     */   
    public Node writeDescriptor(Node parent, String nodeName, WebComponentDescriptor descriptor) {       
        WebServicesDescriptor webServices =
            descriptor.getWebBundleDescriptor().getWebServices();

        // only write servlet runtime elements if there is a runas identity
        // or the servlet is exposed as a web service
        if ( (descriptor.getRunAsIdentity() != null) ||
             webServices.hasEndpointsImplementedBy(descriptor) ) {
            Node servletNode =  appendChild(parent, nodeName);
            appendTextChild(servletNode, RuntimeTagNames.SERVLET_NAME, descriptor.getCanonicalName());

            if( descriptor.getRunAsIdentity() != null ) {
                appendTextChild(servletNode, RuntimeTagNames.PRINCIPAL_NAME,
View Full Code Here

        if(portName == null) {
            portName = "";
        }
       
        // Check if the same endpoint is already defined in webservices.xml
        WebServicesDescriptor wsDesc = bundleDesc.getWebServices();
        WebServiceEndpoint endpoint = wsDesc.getEndpointByName(portComponentName);
        WebService newWS;
        if(endpoint == null) {
            // Check if a service with the same name is already present
            // If so, add this endpoint to the existing service
            if (svcName.length()!=0) {
                newWS = wsDesc.getWebServiceByName(svcName);
            } else {
                newWS = wsDesc.getWebServiceByName(((Class)annElem).getSimpleName());
            }
            if(newWS==null) {
                newWS = new WebService();
                // service name from annotation
                if (svcName.length()!=0) {
                    newWS.setName(svcName);
                } else {
                    newWS.setName(((Class)annElem).getSimpleName());           
                }
                wsDesc.addWebService(newWS);
            }
            endpoint = new WebServiceEndpoint();
            // port-component-name is fully qualified class name
            endpoint.setEndpointName(portComponentName);
            newWS.addEndpoint(endpoint);           
            wsDesc.setSpecVersion(WebServicesDescriptorNode.SPEC_VERSION);
        } else {
            newWS = endpoint.getWebService();
        }

        // If wsdl-service is specified in the descriptor, then the targetnamespace
View Full Code Here

TOP

Related Classes of com.sun.enterprise.deployment.WebServicesDescriptor

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.