dev@javaserverfaces.java.net

Re: [Fwd: [REVIEW] Misc cleanup and small change to PostConstruct/PreDestroy annotation handling.]

From: Ed Burns <ed.burns_at_sun.com>
Date: Fri, 13 Jan 2006 11:07:47 -0800

>>>>> On Thu, 12 Jan 2006 15:08:15 -0800, Ryan Lubke <Ryan.Lubke_at_Sun.COM> said:

RL> Try to save a few cycles by not scanning for PostConstruct/PreDestroy
RL> methods every time a ManagedBean is created. Instead
RL> store the methods into Arrays when the ManagedBeanFactory
RL> is instantiated.

RL> Also remove the hard compile/runtime dependency on
RL> PostConstruct/PreDestory classes.


RL> SECTION: Modified Files
RL> ----------------------------

RL> M jsf-ri/src/com/sun/faces/spi/ManagedBeanFactory.java
RL> - add two methods to ManageBeanFactory SPI
RL> * getPostConstructMethods
RL> * getPreDestroyMethods

RL> M jsf-ri/src/com/sun/faces/config/ManagedBeanFactoryImpl.java
RL> - When factory is created, scan the class for annotated
RL> methods.
RL> - Added enum which will detect the availability of
RL> PostConstruct/PreDestory to remove hard compile/
RL> runtime dependency on said annotations.

That's clever. Where'd you get that idea?

r=edburns