Examples of WebServiceAnnotation


Examples of com.leansoft.mwsc.model.annotation.WebServiceAnnotation

        }
  }
 
    private WebServiceAnnotation getWebServiceAnnotation(Port port) {
        QName name = (QName) port.getProperty(ModelProperties.PROPERTY_WSDL_PORT_TYPE_NAME);
        WebServiceAnnotation wsa = new WebServiceAnnotation();
        wsa.setName(name.getLocalPart());
        wsa.setTargetNamespace(name.getNamespaceURI());
       
        return wsa;
    }
View Full Code Here

Examples of org.apache.axis2.jsr181.WebServiceAnnotation

         * then it will create Complex types foer those , and if the
         * parameters are simple type which decribe in SimpleTypeTable
         * nothing will happen) 2. In the next stage for all the methods
         * messages and port types will be creteated
         */
        WebServiceAnnotation webservice =
                JSR181Helper.INSTANCE.getWebServiceAnnotation(serviceClass);
        if (webservice != null) {
            String tns = webservice.getTargetNamespace();
            if (tns != null && !"".equals(tns)) {
                targetNamespace = tns;
                schemaTargetNameSpace = tns;
            }
            service.setName(Utils.getAnnotatedServiceName(serviceClass, webservice));
View Full Code Here

Examples of org.apache.axis2.jsr181.WebServiceAnnotation

         * then it will create Complex types foer those , and if the
         * parameters are simple type which decribe in SimpleTypeTable
         * nothing will happen) 2. In the next stage for all the methods
         * messages and port types will be creteated
         */
        WebServiceAnnotation webservice =
                JSR181Helper.INSTANCE.getWebServiceAnnotation(serviceClass);
        if (webservice != null) {
            String tns = webservice.getTargetNamespace();
            if (tns != null && !"".equals(tns)) {
                targetNamespace = tns;
                schemaTargetNameSpace = tns;
            }
            service.setName(Utils.getAnnotatedServiceName(serviceClass, webservice));
View Full Code Here

Examples of org.apache.axis2.jsr181.WebServiceAnnotation

                 * then it will create Complex types for those , and if the
                 * parameters are simple type which decribe in SimpleTypeTable
                 * nothing will happen) 2. In the next stage for all the methods
                 * messages and port types will be creteated
                 */
                WebServiceAnnotation annotation =
                        JSR181Helper.INSTANCE.getWebServiceAnnotation(clazz);
                AxisService axisService;
                if (annotation != null) {
                    // try to see whether JAX-WS jars in the class path , if so use them
                    // to process annotated pojo else use annogen to process the pojo class
                    axisService =
                            createAxisService(classLoader,
                                    className,
                                    deploymentFileData.getFile().toURL());
                } else {
                    axisService =
                            createAxisServiceUsingAnnogen(className,
                                    classLoader,
                                    deploymentFileData.getFile().toURL());
                }
                //add the hierarchical path to the service name
                axisService.setName(serviceHierarchy + axisService.getName());
                configCtx.getAxisConfiguration().addService(axisService);

            } else if ("jar".equals(extension)) {
                List<String> classList = Utils.getListOfClasses(deploymentFileData);
                ArrayList<AxisService> axisServiceList = new ArrayList<AxisService>();
                for (String className : classList) {
                    ArrayList<URL> urls = new ArrayList<URL>();
                    urls.add(deploymentFileData.getFile().toURL());
                    urls.add(configCtx.getAxisConfiguration().getRepository());
                    String webLocation = DeploymentEngine.getWebLocationString();
                    if (webLocation != null) {
                        urls.add(new File(webLocation).toURL());
                    }
                    ClassLoader classLoader = Utils.createClassLoader(
                            urls,
                            configCtx.getAxisConfiguration().getSystemClassLoader(),
                            true,
                            (File)configCtx.getAxisConfiguration().
                                    getParameterValue(Constants.Configuration.ARTIFACTS_TEMP_DIR),
                            configCtx.getAxisConfiguration().isChildFirstClassLoading());
                    Thread.currentThread().setContextClassLoader(classLoader);
                    Class<?> clazz = Loader.loadClass(className);

                    /**
                     * Schema generation done in two stage 1. Load all the methods and
                     * create type for methods parameters (if the parameters are Bean
                     * then it will create Complex types for those , and if the
                     * parameters are simple type which decribe in SimpleTypeTable
                     * nothing will happen) 2. In the next stage for all the methods
                     * messages and port types will be creteated
                     */
                    WebServiceAnnotation annotation =
                            JSR181Helper.INSTANCE.getWebServiceAnnotation(clazz);
                    if (annotation != null) {
                        AxisService axisService;
                        axisService =
                                createAxisService(classLoader,
View Full Code Here

Examples of org.apache.axis2.jsr181.WebServiceAnnotation

         * then it will create Complex types foer those , and if the
         * parameters are simple type which decribe in SimpleTypeTable
         * nothing will happen) 2. In the next stage for all the methods
         * messages and port types will be creteated
         */
        WebServiceAnnotation webservice =
                JSR181Helper.INSTANCE.getWebServiceAnnotation(serviceClass);
        if (webservice != null) {
            String tns = webservice.getTargetNamespace();
            if (tns != null && !"".equals(tns)) {
                targetNamespace = tns;
                schemaTargetNameSpace = tns;
            }
            service.setName(Utils.getAnnotatedServiceName(serviceClass, webservice));
View Full Code Here

Examples of org.codehaus.xfire.annotations.WebServiceAnnotation

        control.setReturnValue(false);
        webAnnotations.hasSOAPBindingAnnotation(EchoImpl.class);
        control.setReturnValue(false);
        webAnnotations.hasWebServiceAnnotation(EchoImpl.class);
        control.setReturnValue(true);
        WebServiceAnnotation serviceAnnotation = new WebServiceAnnotation();
        serviceAnnotation.setServiceName("EchoService");
        webAnnotations.getWebServiceAnnotation(EchoImpl.class);
        control.setReturnValue(serviceAnnotation);
        webAnnotations.getWebServiceAnnotation(EchoImpl.class);
        control.setReturnValue(serviceAnnotation);
       
View Full Code Here

Examples of org.codehaus.xfire.annotations.WebServiceAnnotation

        throws Exception
    {
        MockControl control = MockControl.createControl(WebAnnotations.class);
        WebAnnotations webAnnotations = (WebAnnotations) control.getMock();
       
        WebServiceAnnotation serviceAnnotation = new WebServiceAnnotation();
        webAnnotations.getWebServiceAnnotation(Echo.class);
        control.setDefaultReturnValue(serviceAnnotation);
       
        webAnnotations.hasWebServiceAnnotation(Echo.class);
        control.setDefaultReturnValue(true);
       
        webAnnotations.hasWebServiceAnnotation(EchoImpl.class);
        control.setDefaultReturnValue(true);
        webAnnotations.hasHandlerChainAnnotation(EchoImpl.class);
        control.setReturnValue(false);
        webAnnotations.hasSOAPBindingAnnotation(Echo.class);
        control.setReturnValue(false);
        webAnnotations.hasWebServiceAnnotation(EchoImpl.class);
        control.setReturnValue(true);
       
        serviceAnnotation = new WebServiceAnnotation();
        serviceAnnotation.setServiceName("Echo");
        serviceAnnotation.setTargetNamespace("urn:Echo");
        serviceAnnotation.setEndpointInterface(Echo.class.getName());
        webAnnotations.getWebServiceAnnotation(EchoImpl.class);
        control.setReturnValue(serviceAnnotation);
        webAnnotations.getWebServiceAnnotation(EchoImpl.class);
        control.setReturnValue(serviceAnnotation);
       
View Full Code Here

Examples of org.codehaus.xfire.annotations.WebServiceAnnotation

        throws Exception
    {
        MockControl control = MockControl.createControl(WebAnnotations.class);
        WebAnnotations webAnnotations = (WebAnnotations) control.getMock();
       
        WebServiceAnnotation serviceAnnotation = new WebServiceAnnotation();
        webAnnotations.getWebServiceAnnotation(Echo.class);
        control.setDefaultReturnValue(serviceAnnotation);
       
        webAnnotations.hasWebServiceAnnotation(Echo.class);
        control.setDefaultReturnValue(true);
       
        webAnnotations.hasSOAPBindingAnnotation(Echo.class);
        control.setReturnValue(false);
       
        serviceAnnotation = new WebServiceAnnotation();
        serviceAnnotation.setServiceName("Echo");
        serviceAnnotation.setTargetNamespace("urn:Echo");
        webAnnotations.getWebServiceAnnotation(Echo.class);
        control.setDefaultReturnValue(serviceAnnotation);
       
        Method echoMethod = EchoImpl.class.getMethod("echo", new Class[]{String.class});
        webAnnotations.hasWebMethodAnnotation(echoMethod);
View Full Code Here

Examples of org.codehaus.xfire.annotations.WebServiceAnnotation

        return null;
    }

    public WebServiceAnnotation getWebServiceAnnotation(Class aClass)
    {
        return new WebServiceAnnotation();
    }
View Full Code Here

Examples of org.codehaus.xfire.annotations.WebServiceAnnotation

    public WebServiceAnnotation getWebServiceAnnotation(Class clazz)
    {
        WebService webService = (WebService) clazz.getAnnotation(WebService.class);
        if (webService != null)
        {
            WebServiceAnnotation annotation = new WebServiceAnnotation();
            annotation.setEndpointInterface(webService.endpointInterface());
            annotation.setName(webService.name());
            annotation.setServiceName(webService.serviceName());
            annotation.setTargetNamespace(webService.targetNamespace());
            annotation.setPortName(webService.portName());
            annotation.setWsdlLocation(webService.wsdlLocation());
           
            return annotation;
        }
        else
        {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.