Package org.apache.webbeans.spi

Examples of org.apache.webbeans.spi.ResourceInjectionService


    {
        if(getWebBeansType().equals(WebBeansType.MANAGED))
        {
            try
            {
                ResourceInjectionService service = null;
                try
                {
                    service = ServiceLoader.getService(ResourceInjectionService.class);
                   
                }
                catch(Exception e)
                {
                    // When running in tests
                }
               
                if(service != null)
                {
                    service.injectJavaEEResources(instance);  
                }
            }
            catch (Exception e)
            {
                logger.error(OWBLogConst.ERROR_0023, instance);
View Full Code Here


        {
            servletContext = getServletContext(stopObject);
        }

        //Clear the resource injection service
        ResourceInjectionService injectionServices = ServiceLoader.getService(ResourceInjectionService.class);
        if(injectionServices != null)
        {
            injectionServices.clear();
        }

        ContextFactory.cleanUpContextFactory();

        this.cleanupShutdownThreadLocals();
View Full Code Here

    {
        if(getWebBeansType().equals(WebBeansType.MANAGED))
        {
            try
            {
                ResourceInjectionService service = null;
                try
                {
                    service = ServiceLoader.getService(ResourceInjectionService.class);
                   
                }
                catch(Exception e)
                {
                    // When running in tests
                }
               
                if(service != null)
                {
                    service.injectJavaEEResources(instance);  
                }
            }
            catch (Exception e)
            {
                log.error(OWBLogConst.ERROR_0023, instance);
View Full Code Here

        try
        {
            //X TODO cache proxy class!
            ProxyFactory proxyFactory = JavassistProxyFactory.createProxyFactory(this);
           
            ResourceInjectionService resourceService = ServiceLoader.getService(ResourceInjectionService.class);
            this.actualResourceReference = resourceService.getResourceReference(this.resourceReference);
            proxyFactory.setHandler(new ResourceProxyHandler(this.actualResourceReference));
           
            instance = (X)(JavassistProxyFactory.getProxyClass(proxyFactory).newInstance());
        }
        catch (Exception e)
View Full Code Here

        {
            servletContext = getServletContext(stopObject);
        }

        //Clear the resource injection service
        ResourceInjectionService injectionServices = ServiceLoader.getService(ResourceInjectionService.class);
        if(injectionServices != null)
        {
            injectionServices.clear();
        }

        ContextFactory.cleanUpContextFactory();
       
        if (logger.wblWillLogInfo())
View Full Code Here

    {
        if(getWebBeansType().equals(WebBeansType.MANAGED))
        {
            try
            {
                ResourceInjectionService service = null;
                try
                {
                    service = ServiceLoader.getService(ResourceInjectionService.class);
                   
                }catch(Exception e)
                {
                    // When running in tests
                }
               
                if(service != null)
                {
                    service.injectJavaEEResources(instance);  
                }
            }
            catch (Exception e)
            {
                logger.error("Error is occured while injection Java EE Resources for the bean instance : " + instance);
View Full Code Here

        try
        {
            //X TODO cache proxy class!
            ProxyFactory proxyFactory = JavassistProxyFactory.createProxyFactory(this);
           
            ResourceInjectionService resourceService = ServiceLoader.getService(ResourceInjectionService.class);
            this.actualResourceReference = resourceService.getResourceReference(this.resourceReference);
            proxyFactory.setHandler(new ResourceProxyHandler(this.actualResourceReference));
           
            instance = (X)(JavassistProxyFactory.getProxyClass(proxyFactory).newInstance());
        }
        catch (Exception e)
View Full Code Here

    protected void afterStopApplication(Object stopObject) throws Exception
    {

        //Clear the resource injection service
        ResourceInjectionService injectionServices = webBeansContext.getService(ResourceInjectionService.class);
        if(injectionServices != null)
        {
            injectionServices.clear();
        }

        //Comment out for commit OWB-502
        //ContextFactory.cleanUpContextFactory();
View Full Code Here

    }

    protected void afterStopApplication(final Object stopObject) throws Exception {

        //Clear the resource injection service
        final ResourceInjectionService injectionServices = webBeansContext.getService(ResourceInjectionService.class);
        if (injectionServices != null) {
            injectionServices.clear();
        }

        //Comment out for commit OWB-502
        //ContextFactory.cleanUpContextFactory();
View Full Code Here

            //Delete AnnotateTypeCache
            webBeansContext.getAnnotatedElementFactory().clear();

            //After Stop
            //Clear the resource injection service
            final ResourceInjectionService injectionServices = webBeansContext.getService(ResourceInjectionService.class);
            if (injectionServices != null) {
                injectionServices.clear();
            }

            //Comment out for commit OWB-502
            //ContextFactory.cleanUpContextFactory();
View Full Code Here

TOP

Related Classes of org.apache.webbeans.spi.ResourceInjectionService

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.