Package com.sun.faces.spi

Examples of com.sun.faces.spi.InjectionProvider.invokePostConstruct()


                    break;
            }
           
            // now invoke methods marked with @PostConstruct
            if (injectable) {
                injectionProvider.invokePostConstruct(bean);               
            }
           
        } catch (FacesException fe) {
            throw fe;
        } catch (ClassNotFoundException cnfe) {
View Full Code Here


       
        InjectionProvider injectionProvider = associate.getInjectionProvider();
        assertNotNull(injectionProvider);
        try {
            injectionProvider.inject(protectedBean);
            injectionProvider.invokePostConstruct(protectedBean);
            injectionProvider.invokePreDestroy(protectedBean);
            injectionProvider.inject(packagePrivateBean);
            injectionProvider.invokePostConstruct(packagePrivateBean);
            injectionProvider.invokePreDestroy(packagePrivateBean);
            injectionProvider.inject(privateBean);
View Full Code Here

        try {
            injectionProvider.inject(protectedBean);
            injectionProvider.invokePostConstruct(protectedBean);
            injectionProvider.invokePreDestroy(protectedBean);
            injectionProvider.inject(packagePrivateBean);
            injectionProvider.invokePostConstruct(packagePrivateBean);
            injectionProvider.invokePreDestroy(packagePrivateBean);
            injectionProvider.inject(privateBean);
            injectionProvider.invokePostConstruct(privateBean);
            injectionProvider.invokePreDestroy(privateBean);
            injectionProvider.inject(concreteBean);
View Full Code Here

            injectionProvider.invokePreDestroy(protectedBean);
            injectionProvider.inject(packagePrivateBean);
            injectionProvider.invokePostConstruct(packagePrivateBean);
            injectionProvider.invokePreDestroy(packagePrivateBean);
            injectionProvider.inject(privateBean);
            injectionProvider.invokePostConstruct(privateBean);
            injectionProvider.invokePreDestroy(privateBean);
            injectionProvider.inject(concreteBean);
            injectionProvider.invokePostConstruct(concreteBean);
            injectionProvider.invokePreDestroy(concreteBean);
        } catch (Exception e) {
View Full Code Here

            injectionProvider.invokePreDestroy(packagePrivateBean);
            injectionProvider.inject(privateBean);
            injectionProvider.invokePostConstruct(privateBean);
            injectionProvider.invokePreDestroy(privateBean);
            injectionProvider.inject(concreteBean);
            injectionProvider.invokePostConstruct(concreteBean);
            injectionProvider.invokePreDestroy(concreteBean);
        } catch (Exception e) {
            System.out.println(e);
            e.printStackTrace();
            assertTrue(false);
View Full Code Here

        }

        if (map.hasAnnotations(key)) {
            InjectionProvider injectionProvider = associate.getInjectionProvider();
            try {
                injectionProvider.invokePostConstruct(result);
            } catch (InjectionProviderException ex) {
               LOGGER.log(Level.SEVERE, "Unable to invoke @PostConstruct annotated method on instance " + key, ex);
               throw new FacesException(ex);
            }
View Full Code Here

        }

        if (map.hasAnnotations(key)) {
            InjectionProvider injectionProvider = associate.getInjectionProvider();
            try {
                injectionProvider.invokePostConstruct(result);
            } catch (InjectionProviderException ex) {
               LOGGER.log(Level.SEVERE, "Unable to invoke @PostConstruct annotated method on instance " + key, ex);
               throw new FacesException(ex);
            }
View Full Code Here

                    if (classMetadataMap.hasAnnotations(className)) {
                        InjectionProvider injectionProvider = (InjectionProvider) FacesContext.getCurrentInstance().getAttributes().get(ConfigManager.INJECTION_PROVIDER_KEY);

                        try {
                            injectionProvider.invokePostConstruct(returnObject);
                        } catch (InjectionProviderException ex) {
                            LOGGER.log(Level.SEVERE, "Unable to invoke @PostConstruct annotated method on instance " + className, ex);
                            throw new FacesException(ex);
                        }
View Full Code Here

               
                FactoryManager fm = FACTORIES_CACHE.getApplicationFactoryManager(classLoader);
                provider = fm.getInjectionProvider();
                if (null != provider) {
                    provider.inject(result);
                    provider.invokePostConstruct(result);
                } else {
                    if (LOGGER.isLoggable(Level.SEVERE)) {
                        LOGGER.log(Level.SEVERE, "Unable to inject {0} because no InjectionProvider can be found. Does this container implement the Mojarra Injection SPI?", result);
                    }
                }
View Full Code Here

               
                FactoryManager fm = FACTORIES_CACHE.getApplicationFactoryManager(classLoader);
                provider = fm.getInjectionProvider();
                if (null != provider) {
                    provider.inject(result);
                    provider.invokePostConstruct(result);
                } else {
                    if (LOGGER.isLoggable(Level.SEVERE)) {
                        LOGGER.log(Level.SEVERE, "Unable to inject {0} because no InjectionProvider can be found. Does this container implement the Mojarra Injection SPI?", result);
                    }
                }
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.