Timothy Bennett wrote:
Vikas Phonsa wrote:

Guys,
What would be the lifecycle replacement for constructor , if any,  for a
component ?
>
but I view all the following lifecyle methods as a sum of the replacement for a constructor:

<snip/>

I think if it as decomposing the constructor in to these sub-methods.

spot-on! The entire startup lifecycle


enableLogging() / setLogger()
contextualize()
service() / compose()
configure()
initialize()
start()

is sort of like a constructor split into small parts...except that you can't start threads in constructors (well you can, but you shouldn't), so initialize()/start() isn't really part of the "decomposed constructor". That depends on where you create your threads of course, which should be start() IMHO, but inside initialize() it'll work too).

--
cheers,

- Leo Simons

-----------------------------------------------------------------------
Weblog              -- http://leosimons.com/
IoC Component Glue  -- http://jicarilla.org/
Articles & Opinions -- http://articles.leosimons.com/
-----------------------------------------------------------------------
"We started off trying to set up a small anarchist community, but
 people wouldn't obey the rules."
                                                        -- Alan Bennett



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to